tech.ydb.proto.topic.YdbTopic Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of ydb-proto-api Show documentation
Show all versions of ydb-proto-api Show documentation
Generated from Protocol Buffers IDL Java sources
The newest version!
// Generated by the protocol buffer compiler. DO NOT EDIT!
// source: protos/ydb_topic.proto
package tech.ydb.proto.topic;
public final class YdbTopic {
private YdbTopic() {}
public static void registerAllExtensions(
com.google.protobuf.ExtensionRegistryLite registry) {
}
public static void registerAllExtensions(
com.google.protobuf.ExtensionRegistry registry) {
registerAllExtensions(
(com.google.protobuf.ExtensionRegistryLite) registry);
}
/**
* Protobuf enum {@code Ydb.Topic.Codec}
*/
public enum Codec
implements com.google.protobuf.ProtocolMessageEnum {
/**
* CODEC_UNSPECIFIED = 0;
*/
CODEC_UNSPECIFIED(0),
/**
* CODEC_RAW = 1;
*/
CODEC_RAW(1),
/**
* CODEC_GZIP = 2;
*/
CODEC_GZIP(2),
/**
* CODEC_LZOP = 3;
*/
CODEC_LZOP(3),
/**
* CODEC_ZSTD = 4;
*/
CODEC_ZSTD(4),
/**
*
* User-defined codecs from 10000 to 19999
*
*
* CODEC_CUSTOM = 10000;
*/
CODEC_CUSTOM(10000),
UNRECOGNIZED(-1),
;
/**
* CODEC_UNSPECIFIED = 0;
*/
public static final int CODEC_UNSPECIFIED_VALUE = 0;
/**
* CODEC_RAW = 1;
*/
public static final int CODEC_RAW_VALUE = 1;
/**
* CODEC_GZIP = 2;
*/
public static final int CODEC_GZIP_VALUE = 2;
/**
* CODEC_LZOP = 3;
*/
public static final int CODEC_LZOP_VALUE = 3;
/**
* CODEC_ZSTD = 4;
*/
public static final int CODEC_ZSTD_VALUE = 4;
/**
*
* User-defined codecs from 10000 to 19999
*
*
* CODEC_CUSTOM = 10000;
*/
public static final int CODEC_CUSTOM_VALUE = 10000;
public final int getNumber() {
if (this == UNRECOGNIZED) {
throw new java.lang.IllegalArgumentException(
"Can't get the number of an unknown enum value.");
}
return value;
}
/**
* @param value The numeric wire value of the corresponding enum entry.
* @return The enum associated with the given numeric wire value.
* @deprecated Use {@link #forNumber(int)} instead.
*/
@java.lang.Deprecated
public static Codec valueOf(int value) {
return forNumber(value);
}
/**
* @param value The numeric wire value of the corresponding enum entry.
* @return The enum associated with the given numeric wire value.
*/
public static Codec forNumber(int value) {
switch (value) {
case 0: return CODEC_UNSPECIFIED;
case 1: return CODEC_RAW;
case 2: return CODEC_GZIP;
case 3: return CODEC_LZOP;
case 4: return CODEC_ZSTD;
case 10000: return CODEC_CUSTOM;
default: return null;
}
}
public static com.google.protobuf.Internal.EnumLiteMap
internalGetValueMap() {
return internalValueMap;
}
private static final com.google.protobuf.Internal.EnumLiteMap<
Codec> internalValueMap =
new com.google.protobuf.Internal.EnumLiteMap() {
public Codec findValueByNumber(int number) {
return Codec.forNumber(number);
}
};
public final com.google.protobuf.Descriptors.EnumValueDescriptor
getValueDescriptor() {
if (this == UNRECOGNIZED) {
throw new java.lang.IllegalStateException(
"Can't get the descriptor of an unrecognized enum value.");
}
return getDescriptor().getValues().get(ordinal());
}
public final com.google.protobuf.Descriptors.EnumDescriptor
getDescriptorForType() {
return getDescriptor();
}
public static final com.google.protobuf.Descriptors.EnumDescriptor
getDescriptor() {
return tech.ydb.proto.topic.YdbTopic.getDescriptor().getEnumTypes().get(0);
}
private static final Codec[] VALUES = values();
public static Codec valueOf(
com.google.protobuf.Descriptors.EnumValueDescriptor desc) {
if (desc.getType() != getDescriptor()) {
throw new java.lang.IllegalArgumentException(
"EnumValueDescriptor is not for this type.");
}
if (desc.getIndex() == -1) {
return UNRECOGNIZED;
}
return VALUES[desc.getIndex()];
}
private final int value;
private Codec(int value) {
this.value = value;
}
// @@protoc_insertion_point(enum_scope:Ydb.Topic.Codec)
}
/**
*
* Metering mode specifies the method used to determine consumption of resources by the topic.
* This settings will have an effect only in a serverless database.
*
*
* Protobuf enum {@code Ydb.Topic.MeteringMode}
*/
public enum MeteringMode
implements com.google.protobuf.ProtocolMessageEnum {
/**
*
* Use default
*
*
* METERING_MODE_UNSPECIFIED = 0;
*/
METERING_MODE_UNSPECIFIED(0),
/**
*
* Metering based on resource reservation
*
*
* METERING_MODE_RESERVED_CAPACITY = 1;
*/
METERING_MODE_RESERVED_CAPACITY(1),
/**
*
* Metering based on actual consumption. Default.
*
*
* METERING_MODE_REQUEST_UNITS = 2;
*/
METERING_MODE_REQUEST_UNITS(2),
UNRECOGNIZED(-1),
;
/**
*
* Use default
*
*
* METERING_MODE_UNSPECIFIED = 0;
*/
public static final int METERING_MODE_UNSPECIFIED_VALUE = 0;
/**
*
* Metering based on resource reservation
*
*
* METERING_MODE_RESERVED_CAPACITY = 1;
*/
public static final int METERING_MODE_RESERVED_CAPACITY_VALUE = 1;
/**
*
* Metering based on actual consumption. Default.
*
*
* METERING_MODE_REQUEST_UNITS = 2;
*/
public static final int METERING_MODE_REQUEST_UNITS_VALUE = 2;
public final int getNumber() {
if (this == UNRECOGNIZED) {
throw new java.lang.IllegalArgumentException(
"Can't get the number of an unknown enum value.");
}
return value;
}
/**
* @param value The numeric wire value of the corresponding enum entry.
* @return The enum associated with the given numeric wire value.
* @deprecated Use {@link #forNumber(int)} instead.
*/
@java.lang.Deprecated
public static MeteringMode valueOf(int value) {
return forNumber(value);
}
/**
* @param value The numeric wire value of the corresponding enum entry.
* @return The enum associated with the given numeric wire value.
*/
public static MeteringMode forNumber(int value) {
switch (value) {
case 0: return METERING_MODE_UNSPECIFIED;
case 1: return METERING_MODE_RESERVED_CAPACITY;
case 2: return METERING_MODE_REQUEST_UNITS;
default: return null;
}
}
public static com.google.protobuf.Internal.EnumLiteMap
internalGetValueMap() {
return internalValueMap;
}
private static final com.google.protobuf.Internal.EnumLiteMap<
MeteringMode> internalValueMap =
new com.google.protobuf.Internal.EnumLiteMap() {
public MeteringMode findValueByNumber(int number) {
return MeteringMode.forNumber(number);
}
};
public final com.google.protobuf.Descriptors.EnumValueDescriptor
getValueDescriptor() {
if (this == UNRECOGNIZED) {
throw new java.lang.IllegalStateException(
"Can't get the descriptor of an unrecognized enum value.");
}
return getDescriptor().getValues().get(ordinal());
}
public final com.google.protobuf.Descriptors.EnumDescriptor
getDescriptorForType() {
return getDescriptor();
}
public static final com.google.protobuf.Descriptors.EnumDescriptor
getDescriptor() {
return tech.ydb.proto.topic.YdbTopic.getDescriptor().getEnumTypes().get(1);
}
private static final MeteringMode[] VALUES = values();
public static MeteringMode valueOf(
com.google.protobuf.Descriptors.EnumValueDescriptor desc) {
if (desc.getType() != getDescriptor()) {
throw new java.lang.IllegalArgumentException(
"EnumValueDescriptor is not for this type.");
}
if (desc.getIndex() == -1) {
return UNRECOGNIZED;
}
return VALUES[desc.getIndex()];
}
private final int value;
private MeteringMode(int value) {
this.value = value;
}
// @@protoc_insertion_point(enum_scope:Ydb.Topic.MeteringMode)
}
public interface SupportedCodecsOrBuilder extends
// @@protoc_insertion_point(interface_extends:Ydb.Topic.SupportedCodecs)
com.google.protobuf.MessageOrBuilder {
/**
*
* List of supported codecs.
* See enum Codec above for values.
*
*
* repeated int32 codecs = 1 [(.Ydb.size) = { ... }
* @return A list containing the codecs.
*/
java.util.List getCodecsList();
/**
*
* List of supported codecs.
* See enum Codec above for values.
*
*
* repeated int32 codecs = 1 [(.Ydb.size) = { ... }
* @return The count of codecs.
*/
int getCodecsCount();
/**
*
* List of supported codecs.
* See enum Codec above for values.
*
*
* repeated int32 codecs = 1 [(.Ydb.size) = { ... }
* @param index The index of the element to return.
* @return The codecs at the given index.
*/
int getCodecs(int index);
}
/**
*
* Description of supported codecs.
*
*
* Protobuf type {@code Ydb.Topic.SupportedCodecs}
*/
public static final class SupportedCodecs extends
com.google.protobuf.GeneratedMessageV3 implements
// @@protoc_insertion_point(message_implements:Ydb.Topic.SupportedCodecs)
SupportedCodecsOrBuilder {
private static final long serialVersionUID = 0L;
// Use SupportedCodecs.newBuilder() to construct.
private SupportedCodecs(com.google.protobuf.GeneratedMessageV3.Builder> builder) {
super(builder);
}
private SupportedCodecs() {
codecs_ = emptyIntList();
}
@java.lang.Override
@SuppressWarnings({"unused"})
protected java.lang.Object newInstance(
UnusedPrivateParameter unused) {
return new SupportedCodecs();
}
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_SupportedCodecs_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_SupportedCodecs_fieldAccessorTable
.ensureFieldAccessorsInitialized(
tech.ydb.proto.topic.YdbTopic.SupportedCodecs.class, tech.ydb.proto.topic.YdbTopic.SupportedCodecs.Builder.class);
}
public static final int CODECS_FIELD_NUMBER = 1;
@SuppressWarnings("serial")
private com.google.protobuf.Internal.IntList codecs_ =
emptyIntList();
/**
*
* List of supported codecs.
* See enum Codec above for values.
*
*
* repeated int32 codecs = 1 [(.Ydb.size) = { ... }
* @return A list containing the codecs.
*/
@java.lang.Override
public java.util.List
getCodecsList() {
return codecs_;
}
/**
*
* List of supported codecs.
* See enum Codec above for values.
*
*
* repeated int32 codecs = 1 [(.Ydb.size) = { ... }
* @return The count of codecs.
*/
public int getCodecsCount() {
return codecs_.size();
}
/**
*
* List of supported codecs.
* See enum Codec above for values.
*
*
* repeated int32 codecs = 1 [(.Ydb.size) = { ... }
* @param index The index of the element to return.
* @return The codecs at the given index.
*/
public int getCodecs(int index) {
return codecs_.getInt(index);
}
private int codecsMemoizedSerializedSize = -1;
private byte memoizedIsInitialized = -1;
@java.lang.Override
public final boolean isInitialized() {
byte isInitialized = memoizedIsInitialized;
if (isInitialized == 1) return true;
if (isInitialized == 0) return false;
memoizedIsInitialized = 1;
return true;
}
@java.lang.Override
public void writeTo(com.google.protobuf.CodedOutputStream output)
throws java.io.IOException {
getSerializedSize();
if (getCodecsList().size() > 0) {
output.writeUInt32NoTag(10);
output.writeUInt32NoTag(codecsMemoizedSerializedSize);
}
for (int i = 0; i < codecs_.size(); i++) {
output.writeInt32NoTag(codecs_.getInt(i));
}
getUnknownFields().writeTo(output);
}
@java.lang.Override
public int getSerializedSize() {
int size = memoizedSize;
if (size != -1) return size;
size = 0;
{
int dataSize = 0;
for (int i = 0; i < codecs_.size(); i++) {
dataSize += com.google.protobuf.CodedOutputStream
.computeInt32SizeNoTag(codecs_.getInt(i));
}
size += dataSize;
if (!getCodecsList().isEmpty()) {
size += 1;
size += com.google.protobuf.CodedOutputStream
.computeInt32SizeNoTag(dataSize);
}
codecsMemoizedSerializedSize = dataSize;
}
size += getUnknownFields().getSerializedSize();
memoizedSize = size;
return size;
}
@java.lang.Override
public boolean equals(final java.lang.Object obj) {
if (obj == this) {
return true;
}
if (!(obj instanceof tech.ydb.proto.topic.YdbTopic.SupportedCodecs)) {
return super.equals(obj);
}
tech.ydb.proto.topic.YdbTopic.SupportedCodecs other = (tech.ydb.proto.topic.YdbTopic.SupportedCodecs) obj;
if (!getCodecsList()
.equals(other.getCodecsList())) return false;
if (!getUnknownFields().equals(other.getUnknownFields())) return false;
return true;
}
@java.lang.Override
public int hashCode() {
if (memoizedHashCode != 0) {
return memoizedHashCode;
}
int hash = 41;
hash = (19 * hash) + getDescriptor().hashCode();
if (getCodecsCount() > 0) {
hash = (37 * hash) + CODECS_FIELD_NUMBER;
hash = (53 * hash) + getCodecsList().hashCode();
}
hash = (29 * hash) + getUnknownFields().hashCode();
memoizedHashCode = hash;
return hash;
}
public static tech.ydb.proto.topic.YdbTopic.SupportedCodecs parseFrom(
java.nio.ByteBuffer data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static tech.ydb.proto.topic.YdbTopic.SupportedCodecs parseFrom(
java.nio.ByteBuffer data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.SupportedCodecs parseFrom(
com.google.protobuf.ByteString data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static tech.ydb.proto.topic.YdbTopic.SupportedCodecs parseFrom(
com.google.protobuf.ByteString data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.SupportedCodecs parseFrom(byte[] data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static tech.ydb.proto.topic.YdbTopic.SupportedCodecs parseFrom(
byte[] data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.SupportedCodecs parseFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static tech.ydb.proto.topic.YdbTopic.SupportedCodecs parseFrom(
java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.SupportedCodecs parseDelimitedFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input);
}
public static tech.ydb.proto.topic.YdbTopic.SupportedCodecs parseDelimitedFrom(
java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.SupportedCodecs parseFrom(
com.google.protobuf.CodedInputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static tech.ydb.proto.topic.YdbTopic.SupportedCodecs parseFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry);
}
@java.lang.Override
public Builder newBuilderForType() { return newBuilder(); }
public static Builder newBuilder() {
return DEFAULT_INSTANCE.toBuilder();
}
public static Builder newBuilder(tech.ydb.proto.topic.YdbTopic.SupportedCodecs prototype) {
return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
}
@java.lang.Override
public Builder toBuilder() {
return this == DEFAULT_INSTANCE
? new Builder() : new Builder().mergeFrom(this);
}
@java.lang.Override
protected Builder newBuilderForType(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
Builder builder = new Builder(parent);
return builder;
}
/**
*
* Description of supported codecs.
*
*
* Protobuf type {@code Ydb.Topic.SupportedCodecs}
*/
public static final class Builder extends
com.google.protobuf.GeneratedMessageV3.Builder implements
// @@protoc_insertion_point(builder_implements:Ydb.Topic.SupportedCodecs)
tech.ydb.proto.topic.YdbTopic.SupportedCodecsOrBuilder {
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_SupportedCodecs_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_SupportedCodecs_fieldAccessorTable
.ensureFieldAccessorsInitialized(
tech.ydb.proto.topic.YdbTopic.SupportedCodecs.class, tech.ydb.proto.topic.YdbTopic.SupportedCodecs.Builder.class);
}
// Construct using tech.ydb.proto.topic.YdbTopic.SupportedCodecs.newBuilder()
private Builder() {
}
private Builder(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
super(parent);
}
@java.lang.Override
public Builder clear() {
super.clear();
bitField0_ = 0;
codecs_ = emptyIntList();
return this;
}
@java.lang.Override
public com.google.protobuf.Descriptors.Descriptor
getDescriptorForType() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_SupportedCodecs_descriptor;
}
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.SupportedCodecs getDefaultInstanceForType() {
return tech.ydb.proto.topic.YdbTopic.SupportedCodecs.getDefaultInstance();
}
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.SupportedCodecs build() {
tech.ydb.proto.topic.YdbTopic.SupportedCodecs result = buildPartial();
if (!result.isInitialized()) {
throw newUninitializedMessageException(result);
}
return result;
}
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.SupportedCodecs buildPartial() {
tech.ydb.proto.topic.YdbTopic.SupportedCodecs result = new tech.ydb.proto.topic.YdbTopic.SupportedCodecs(this);
if (bitField0_ != 0) { buildPartial0(result); }
onBuilt();
return result;
}
private void buildPartial0(tech.ydb.proto.topic.YdbTopic.SupportedCodecs result) {
int from_bitField0_ = bitField0_;
if (((from_bitField0_ & 0x00000001) != 0)) {
codecs_.makeImmutable();
result.codecs_ = codecs_;
}
}
@java.lang.Override
public Builder clone() {
return super.clone();
}
@java.lang.Override
public Builder setField(
com.google.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) {
return super.setField(field, value);
}
@java.lang.Override
public Builder clearField(
com.google.protobuf.Descriptors.FieldDescriptor field) {
return super.clearField(field);
}
@java.lang.Override
public Builder clearOneof(
com.google.protobuf.Descriptors.OneofDescriptor oneof) {
return super.clearOneof(oneof);
}
@java.lang.Override
public Builder setRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
int index, java.lang.Object value) {
return super.setRepeatedField(field, index, value);
}
@java.lang.Override
public Builder addRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) {
return super.addRepeatedField(field, value);
}
@java.lang.Override
public Builder mergeFrom(com.google.protobuf.Message other) {
if (other instanceof tech.ydb.proto.topic.YdbTopic.SupportedCodecs) {
return mergeFrom((tech.ydb.proto.topic.YdbTopic.SupportedCodecs)other);
} else {
super.mergeFrom(other);
return this;
}
}
public Builder mergeFrom(tech.ydb.proto.topic.YdbTopic.SupportedCodecs other) {
if (other == tech.ydb.proto.topic.YdbTopic.SupportedCodecs.getDefaultInstance()) return this;
if (!other.codecs_.isEmpty()) {
if (codecs_.isEmpty()) {
codecs_ = other.codecs_;
codecs_.makeImmutable();
bitField0_ |= 0x00000001;
} else {
ensureCodecsIsMutable();
codecs_.addAll(other.codecs_);
}
onChanged();
}
this.mergeUnknownFields(other.getUnknownFields());
onChanged();
return this;
}
@java.lang.Override
public final boolean isInitialized() {
return true;
}
@java.lang.Override
public Builder mergeFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
if (extensionRegistry == null) {
throw new java.lang.NullPointerException();
}
try {
boolean done = false;
while (!done) {
int tag = input.readTag();
switch (tag) {
case 0:
done = true;
break;
case 8: {
int v = input.readInt32();
ensureCodecsIsMutable();
codecs_.addInt(v);
break;
} // case 8
case 10: {
int length = input.readRawVarint32();
int limit = input.pushLimit(length);
ensureCodecsIsMutable();
while (input.getBytesUntilLimit() > 0) {
codecs_.addInt(input.readInt32());
}
input.popLimit(limit);
break;
} // case 10
default: {
if (!super.parseUnknownField(input, extensionRegistry, tag)) {
done = true; // was an endgroup tag
}
break;
} // default:
} // switch (tag)
} // while (!done)
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.unwrapIOException();
} finally {
onChanged();
} // finally
return this;
}
private int bitField0_;
private com.google.protobuf.Internal.IntList codecs_ = emptyIntList();
private void ensureCodecsIsMutable() {
if (!codecs_.isModifiable()) {
codecs_ = makeMutableCopy(codecs_);
}
bitField0_ |= 0x00000001;
}
/**
*
* List of supported codecs.
* See enum Codec above for values.
*
*
* repeated int32 codecs = 1 [(.Ydb.size) = { ... }
* @return A list containing the codecs.
*/
public java.util.List
getCodecsList() {
codecs_.makeImmutable();
return codecs_;
}
/**
*
* List of supported codecs.
* See enum Codec above for values.
*
*
* repeated int32 codecs = 1 [(.Ydb.size) = { ... }
* @return The count of codecs.
*/
public int getCodecsCount() {
return codecs_.size();
}
/**
*
* List of supported codecs.
* See enum Codec above for values.
*
*
* repeated int32 codecs = 1 [(.Ydb.size) = { ... }
* @param index The index of the element to return.
* @return The codecs at the given index.
*/
public int getCodecs(int index) {
return codecs_.getInt(index);
}
/**
*
* List of supported codecs.
* See enum Codec above for values.
*
*
* repeated int32 codecs = 1 [(.Ydb.size) = { ... }
* @param index The index to set the value at.
* @param value The codecs to set.
* @return This builder for chaining.
*/
public Builder setCodecs(
int index, int value) {
ensureCodecsIsMutable();
codecs_.setInt(index, value);
bitField0_ |= 0x00000001;
onChanged();
return this;
}
/**
*
* List of supported codecs.
* See enum Codec above for values.
*
*
* repeated int32 codecs = 1 [(.Ydb.size) = { ... }
* @param value The codecs to add.
* @return This builder for chaining.
*/
public Builder addCodecs(int value) {
ensureCodecsIsMutable();
codecs_.addInt(value);
bitField0_ |= 0x00000001;
onChanged();
return this;
}
/**
*
* List of supported codecs.
* See enum Codec above for values.
*
*
* repeated int32 codecs = 1 [(.Ydb.size) = { ... }
* @param values The codecs to add.
* @return This builder for chaining.
*/
public Builder addAllCodecs(
java.lang.Iterable extends java.lang.Integer> values) {
ensureCodecsIsMutable();
com.google.protobuf.AbstractMessageLite.Builder.addAll(
values, codecs_);
bitField0_ |= 0x00000001;
onChanged();
return this;
}
/**
*
* List of supported codecs.
* See enum Codec above for values.
*
*
* repeated int32 codecs = 1 [(.Ydb.size) = { ... }
* @return This builder for chaining.
*/
public Builder clearCodecs() {
codecs_ = emptyIntList();
bitField0_ = (bitField0_ & ~0x00000001);
onChanged();
return this;
}
@java.lang.Override
public final Builder setUnknownFields(
final com.google.protobuf.UnknownFieldSet unknownFields) {
return super.setUnknownFields(unknownFields);
}
@java.lang.Override
public final Builder mergeUnknownFields(
final com.google.protobuf.UnknownFieldSet unknownFields) {
return super.mergeUnknownFields(unknownFields);
}
// @@protoc_insertion_point(builder_scope:Ydb.Topic.SupportedCodecs)
}
// @@protoc_insertion_point(class_scope:Ydb.Topic.SupportedCodecs)
private static final tech.ydb.proto.topic.YdbTopic.SupportedCodecs DEFAULT_INSTANCE;
static {
DEFAULT_INSTANCE = new tech.ydb.proto.topic.YdbTopic.SupportedCodecs();
}
public static tech.ydb.proto.topic.YdbTopic.SupportedCodecs getDefaultInstance() {
return DEFAULT_INSTANCE;
}
private static final com.google.protobuf.Parser
PARSER = new com.google.protobuf.AbstractParser() {
@java.lang.Override
public SupportedCodecs parsePartialFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
Builder builder = newBuilder();
try {
builder.mergeFrom(input, extensionRegistry);
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.setUnfinishedMessage(builder.buildPartial());
} catch (com.google.protobuf.UninitializedMessageException e) {
throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial());
} catch (java.io.IOException e) {
throw new com.google.protobuf.InvalidProtocolBufferException(e)
.setUnfinishedMessage(builder.buildPartial());
}
return builder.buildPartial();
}
};
public static com.google.protobuf.Parser parser() {
return PARSER;
}
@java.lang.Override
public com.google.protobuf.Parser getParserForType() {
return PARSER;
}
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.SupportedCodecs getDefaultInstanceForType() {
return DEFAULT_INSTANCE;
}
}
public interface OffsetsRangeOrBuilder extends
// @@protoc_insertion_point(interface_extends:Ydb.Topic.OffsetsRange)
com.google.protobuf.MessageOrBuilder {
/**
* int64 start = 1;
* @return The start.
*/
long getStart();
/**
* int64 end = 2;
* @return The end.
*/
long getEnd();
}
/**
*
* Represents range [start, end).
* I.e. (end - 1) is the greatest of offsets, included in non-empty range.
*
*
* Protobuf type {@code Ydb.Topic.OffsetsRange}
*/
public static final class OffsetsRange extends
com.google.protobuf.GeneratedMessageV3 implements
// @@protoc_insertion_point(message_implements:Ydb.Topic.OffsetsRange)
OffsetsRangeOrBuilder {
private static final long serialVersionUID = 0L;
// Use OffsetsRange.newBuilder() to construct.
private OffsetsRange(com.google.protobuf.GeneratedMessageV3.Builder> builder) {
super(builder);
}
private OffsetsRange() {
}
@java.lang.Override
@SuppressWarnings({"unused"})
protected java.lang.Object newInstance(
UnusedPrivateParameter unused) {
return new OffsetsRange();
}
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_OffsetsRange_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_OffsetsRange_fieldAccessorTable
.ensureFieldAccessorsInitialized(
tech.ydb.proto.topic.YdbTopic.OffsetsRange.class, tech.ydb.proto.topic.YdbTopic.OffsetsRange.Builder.class);
}
public static final int START_FIELD_NUMBER = 1;
private long start_ = 0L;
/**
* int64 start = 1;
* @return The start.
*/
@java.lang.Override
public long getStart() {
return start_;
}
public static final int END_FIELD_NUMBER = 2;
private long end_ = 0L;
/**
* int64 end = 2;
* @return The end.
*/
@java.lang.Override
public long getEnd() {
return end_;
}
private byte memoizedIsInitialized = -1;
@java.lang.Override
public final boolean isInitialized() {
byte isInitialized = memoizedIsInitialized;
if (isInitialized == 1) return true;
if (isInitialized == 0) return false;
memoizedIsInitialized = 1;
return true;
}
@java.lang.Override
public void writeTo(com.google.protobuf.CodedOutputStream output)
throws java.io.IOException {
if (start_ != 0L) {
output.writeInt64(1, start_);
}
if (end_ != 0L) {
output.writeInt64(2, end_);
}
getUnknownFields().writeTo(output);
}
@java.lang.Override
public int getSerializedSize() {
int size = memoizedSize;
if (size != -1) return size;
size = 0;
if (start_ != 0L) {
size += com.google.protobuf.CodedOutputStream
.computeInt64Size(1, start_);
}
if (end_ != 0L) {
size += com.google.protobuf.CodedOutputStream
.computeInt64Size(2, end_);
}
size += getUnknownFields().getSerializedSize();
memoizedSize = size;
return size;
}
@java.lang.Override
public boolean equals(final java.lang.Object obj) {
if (obj == this) {
return true;
}
if (!(obj instanceof tech.ydb.proto.topic.YdbTopic.OffsetsRange)) {
return super.equals(obj);
}
tech.ydb.proto.topic.YdbTopic.OffsetsRange other = (tech.ydb.proto.topic.YdbTopic.OffsetsRange) obj;
if (getStart()
!= other.getStart()) return false;
if (getEnd()
!= other.getEnd()) return false;
if (!getUnknownFields().equals(other.getUnknownFields())) return false;
return true;
}
@java.lang.Override
public int hashCode() {
if (memoizedHashCode != 0) {
return memoizedHashCode;
}
int hash = 41;
hash = (19 * hash) + getDescriptor().hashCode();
hash = (37 * hash) + START_FIELD_NUMBER;
hash = (53 * hash) + com.google.protobuf.Internal.hashLong(
getStart());
hash = (37 * hash) + END_FIELD_NUMBER;
hash = (53 * hash) + com.google.protobuf.Internal.hashLong(
getEnd());
hash = (29 * hash) + getUnknownFields().hashCode();
memoizedHashCode = hash;
return hash;
}
public static tech.ydb.proto.topic.YdbTopic.OffsetsRange parseFrom(
java.nio.ByteBuffer data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static tech.ydb.proto.topic.YdbTopic.OffsetsRange parseFrom(
java.nio.ByteBuffer data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.OffsetsRange parseFrom(
com.google.protobuf.ByteString data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static tech.ydb.proto.topic.YdbTopic.OffsetsRange parseFrom(
com.google.protobuf.ByteString data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.OffsetsRange parseFrom(byte[] data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static tech.ydb.proto.topic.YdbTopic.OffsetsRange parseFrom(
byte[] data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.OffsetsRange parseFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static tech.ydb.proto.topic.YdbTopic.OffsetsRange parseFrom(
java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.OffsetsRange parseDelimitedFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input);
}
public static tech.ydb.proto.topic.YdbTopic.OffsetsRange parseDelimitedFrom(
java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.OffsetsRange parseFrom(
com.google.protobuf.CodedInputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static tech.ydb.proto.topic.YdbTopic.OffsetsRange parseFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry);
}
@java.lang.Override
public Builder newBuilderForType() { return newBuilder(); }
public static Builder newBuilder() {
return DEFAULT_INSTANCE.toBuilder();
}
public static Builder newBuilder(tech.ydb.proto.topic.YdbTopic.OffsetsRange prototype) {
return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
}
@java.lang.Override
public Builder toBuilder() {
return this == DEFAULT_INSTANCE
? new Builder() : new Builder().mergeFrom(this);
}
@java.lang.Override
protected Builder newBuilderForType(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
Builder builder = new Builder(parent);
return builder;
}
/**
*
* Represents range [start, end).
* I.e. (end - 1) is the greatest of offsets, included in non-empty range.
*
*
* Protobuf type {@code Ydb.Topic.OffsetsRange}
*/
public static final class Builder extends
com.google.protobuf.GeneratedMessageV3.Builder implements
// @@protoc_insertion_point(builder_implements:Ydb.Topic.OffsetsRange)
tech.ydb.proto.topic.YdbTopic.OffsetsRangeOrBuilder {
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_OffsetsRange_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_OffsetsRange_fieldAccessorTable
.ensureFieldAccessorsInitialized(
tech.ydb.proto.topic.YdbTopic.OffsetsRange.class, tech.ydb.proto.topic.YdbTopic.OffsetsRange.Builder.class);
}
// Construct using tech.ydb.proto.topic.YdbTopic.OffsetsRange.newBuilder()
private Builder() {
}
private Builder(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
super(parent);
}
@java.lang.Override
public Builder clear() {
super.clear();
bitField0_ = 0;
start_ = 0L;
end_ = 0L;
return this;
}
@java.lang.Override
public com.google.protobuf.Descriptors.Descriptor
getDescriptorForType() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_OffsetsRange_descriptor;
}
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.OffsetsRange getDefaultInstanceForType() {
return tech.ydb.proto.topic.YdbTopic.OffsetsRange.getDefaultInstance();
}
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.OffsetsRange build() {
tech.ydb.proto.topic.YdbTopic.OffsetsRange result = buildPartial();
if (!result.isInitialized()) {
throw newUninitializedMessageException(result);
}
return result;
}
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.OffsetsRange buildPartial() {
tech.ydb.proto.topic.YdbTopic.OffsetsRange result = new tech.ydb.proto.topic.YdbTopic.OffsetsRange(this);
if (bitField0_ != 0) { buildPartial0(result); }
onBuilt();
return result;
}
private void buildPartial0(tech.ydb.proto.topic.YdbTopic.OffsetsRange result) {
int from_bitField0_ = bitField0_;
if (((from_bitField0_ & 0x00000001) != 0)) {
result.start_ = start_;
}
if (((from_bitField0_ & 0x00000002) != 0)) {
result.end_ = end_;
}
}
@java.lang.Override
public Builder clone() {
return super.clone();
}
@java.lang.Override
public Builder setField(
com.google.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) {
return super.setField(field, value);
}
@java.lang.Override
public Builder clearField(
com.google.protobuf.Descriptors.FieldDescriptor field) {
return super.clearField(field);
}
@java.lang.Override
public Builder clearOneof(
com.google.protobuf.Descriptors.OneofDescriptor oneof) {
return super.clearOneof(oneof);
}
@java.lang.Override
public Builder setRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
int index, java.lang.Object value) {
return super.setRepeatedField(field, index, value);
}
@java.lang.Override
public Builder addRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) {
return super.addRepeatedField(field, value);
}
@java.lang.Override
public Builder mergeFrom(com.google.protobuf.Message other) {
if (other instanceof tech.ydb.proto.topic.YdbTopic.OffsetsRange) {
return mergeFrom((tech.ydb.proto.topic.YdbTopic.OffsetsRange)other);
} else {
super.mergeFrom(other);
return this;
}
}
public Builder mergeFrom(tech.ydb.proto.topic.YdbTopic.OffsetsRange other) {
if (other == tech.ydb.proto.topic.YdbTopic.OffsetsRange.getDefaultInstance()) return this;
if (other.getStart() != 0L) {
setStart(other.getStart());
}
if (other.getEnd() != 0L) {
setEnd(other.getEnd());
}
this.mergeUnknownFields(other.getUnknownFields());
onChanged();
return this;
}
@java.lang.Override
public final boolean isInitialized() {
return true;
}
@java.lang.Override
public Builder mergeFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
if (extensionRegistry == null) {
throw new java.lang.NullPointerException();
}
try {
boolean done = false;
while (!done) {
int tag = input.readTag();
switch (tag) {
case 0:
done = true;
break;
case 8: {
start_ = input.readInt64();
bitField0_ |= 0x00000001;
break;
} // case 8
case 16: {
end_ = input.readInt64();
bitField0_ |= 0x00000002;
break;
} // case 16
default: {
if (!super.parseUnknownField(input, extensionRegistry, tag)) {
done = true; // was an endgroup tag
}
break;
} // default:
} // switch (tag)
} // while (!done)
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.unwrapIOException();
} finally {
onChanged();
} // finally
return this;
}
private int bitField0_;
private long start_ ;
/**
* int64 start = 1;
* @return The start.
*/
@java.lang.Override
public long getStart() {
return start_;
}
/**
* int64 start = 1;
* @param value The start to set.
* @return This builder for chaining.
*/
public Builder setStart(long value) {
start_ = value;
bitField0_ |= 0x00000001;
onChanged();
return this;
}
/**
* int64 start = 1;
* @return This builder for chaining.
*/
public Builder clearStart() {
bitField0_ = (bitField0_ & ~0x00000001);
start_ = 0L;
onChanged();
return this;
}
private long end_ ;
/**
* int64 end = 2;
* @return The end.
*/
@java.lang.Override
public long getEnd() {
return end_;
}
/**
* int64 end = 2;
* @param value The end to set.
* @return This builder for chaining.
*/
public Builder setEnd(long value) {
end_ = value;
bitField0_ |= 0x00000002;
onChanged();
return this;
}
/**
* int64 end = 2;
* @return This builder for chaining.
*/
public Builder clearEnd() {
bitField0_ = (bitField0_ & ~0x00000002);
end_ = 0L;
onChanged();
return this;
}
@java.lang.Override
public final Builder setUnknownFields(
final com.google.protobuf.UnknownFieldSet unknownFields) {
return super.setUnknownFields(unknownFields);
}
@java.lang.Override
public final Builder mergeUnknownFields(
final com.google.protobuf.UnknownFieldSet unknownFields) {
return super.mergeUnknownFields(unknownFields);
}
// @@protoc_insertion_point(builder_scope:Ydb.Topic.OffsetsRange)
}
// @@protoc_insertion_point(class_scope:Ydb.Topic.OffsetsRange)
private static final tech.ydb.proto.topic.YdbTopic.OffsetsRange DEFAULT_INSTANCE;
static {
DEFAULT_INSTANCE = new tech.ydb.proto.topic.YdbTopic.OffsetsRange();
}
public static tech.ydb.proto.topic.YdbTopic.OffsetsRange getDefaultInstance() {
return DEFAULT_INSTANCE;
}
private static final com.google.protobuf.Parser
PARSER = new com.google.protobuf.AbstractParser() {
@java.lang.Override
public OffsetsRange parsePartialFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
Builder builder = newBuilder();
try {
builder.mergeFrom(input, extensionRegistry);
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.setUnfinishedMessage(builder.buildPartial());
} catch (com.google.protobuf.UninitializedMessageException e) {
throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial());
} catch (java.io.IOException e) {
throw new com.google.protobuf.InvalidProtocolBufferException(e)
.setUnfinishedMessage(builder.buildPartial());
}
return builder.buildPartial();
}
};
public static com.google.protobuf.Parser parser() {
return PARSER;
}
@java.lang.Override
public com.google.protobuf.Parser getParserForType() {
return PARSER;
}
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.OffsetsRange getDefaultInstanceForType() {
return DEFAULT_INSTANCE;
}
}
public interface UpdateTokenRequestOrBuilder extends
// @@protoc_insertion_point(interface_extends:Ydb.Topic.UpdateTokenRequest)
com.google.protobuf.MessageOrBuilder {
/**
* string token = 1 [(.Ydb.sensitive) = true];
* @return The token.
*/
java.lang.String getToken();
/**
* string token = 1 [(.Ydb.sensitive) = true];
* @return The bytes for token.
*/
com.google.protobuf.ByteString
getTokenBytes();
}
/**
*
* In-session reauthentication and reauthorization, lets user increase session lifetime.
* Client should wait for UpdateTokenResponse before sending next UpdateTokenRequest.
*
*
* Protobuf type {@code Ydb.Topic.UpdateTokenRequest}
*/
public static final class UpdateTokenRequest extends
com.google.protobuf.GeneratedMessageV3 implements
// @@protoc_insertion_point(message_implements:Ydb.Topic.UpdateTokenRequest)
UpdateTokenRequestOrBuilder {
private static final long serialVersionUID = 0L;
// Use UpdateTokenRequest.newBuilder() to construct.
private UpdateTokenRequest(com.google.protobuf.GeneratedMessageV3.Builder> builder) {
super(builder);
}
private UpdateTokenRequest() {
token_ = "";
}
@java.lang.Override
@SuppressWarnings({"unused"})
protected java.lang.Object newInstance(
UnusedPrivateParameter unused) {
return new UpdateTokenRequest();
}
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_UpdateTokenRequest_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_UpdateTokenRequest_fieldAccessorTable
.ensureFieldAccessorsInitialized(
tech.ydb.proto.topic.YdbTopic.UpdateTokenRequest.class, tech.ydb.proto.topic.YdbTopic.UpdateTokenRequest.Builder.class);
}
public static final int TOKEN_FIELD_NUMBER = 1;
@SuppressWarnings("serial")
private volatile java.lang.Object token_ = "";
/**
* string token = 1 [(.Ydb.sensitive) = true];
* @return The token.
*/
@java.lang.Override
public java.lang.String getToken() {
java.lang.Object ref = token_;
if (ref instanceof java.lang.String) {
return (java.lang.String) ref;
} else {
com.google.protobuf.ByteString bs =
(com.google.protobuf.ByteString) ref;
java.lang.String s = bs.toStringUtf8();
token_ = s;
return s;
}
}
/**
* string token = 1 [(.Ydb.sensitive) = true];
* @return The bytes for token.
*/
@java.lang.Override
public com.google.protobuf.ByteString
getTokenBytes() {
java.lang.Object ref = token_;
if (ref instanceof java.lang.String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
token_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
private byte memoizedIsInitialized = -1;
@java.lang.Override
public final boolean isInitialized() {
byte isInitialized = memoizedIsInitialized;
if (isInitialized == 1) return true;
if (isInitialized == 0) return false;
memoizedIsInitialized = 1;
return true;
}
@java.lang.Override
public void writeTo(com.google.protobuf.CodedOutputStream output)
throws java.io.IOException {
if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(token_)) {
com.google.protobuf.GeneratedMessageV3.writeString(output, 1, token_);
}
getUnknownFields().writeTo(output);
}
@java.lang.Override
public int getSerializedSize() {
int size = memoizedSize;
if (size != -1) return size;
size = 0;
if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(token_)) {
size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, token_);
}
size += getUnknownFields().getSerializedSize();
memoizedSize = size;
return size;
}
@java.lang.Override
public boolean equals(final java.lang.Object obj) {
if (obj == this) {
return true;
}
if (!(obj instanceof tech.ydb.proto.topic.YdbTopic.UpdateTokenRequest)) {
return super.equals(obj);
}
tech.ydb.proto.topic.YdbTopic.UpdateTokenRequest other = (tech.ydb.proto.topic.YdbTopic.UpdateTokenRequest) obj;
if (!getToken()
.equals(other.getToken())) return false;
if (!getUnknownFields().equals(other.getUnknownFields())) return false;
return true;
}
@java.lang.Override
public int hashCode() {
if (memoizedHashCode != 0) {
return memoizedHashCode;
}
int hash = 41;
hash = (19 * hash) + getDescriptor().hashCode();
hash = (37 * hash) + TOKEN_FIELD_NUMBER;
hash = (53 * hash) + getToken().hashCode();
hash = (29 * hash) + getUnknownFields().hashCode();
memoizedHashCode = hash;
return hash;
}
public static tech.ydb.proto.topic.YdbTopic.UpdateTokenRequest parseFrom(
java.nio.ByteBuffer data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static tech.ydb.proto.topic.YdbTopic.UpdateTokenRequest parseFrom(
java.nio.ByteBuffer data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.UpdateTokenRequest parseFrom(
com.google.protobuf.ByteString data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static tech.ydb.proto.topic.YdbTopic.UpdateTokenRequest parseFrom(
com.google.protobuf.ByteString data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.UpdateTokenRequest parseFrom(byte[] data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static tech.ydb.proto.topic.YdbTopic.UpdateTokenRequest parseFrom(
byte[] data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.UpdateTokenRequest parseFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static tech.ydb.proto.topic.YdbTopic.UpdateTokenRequest parseFrom(
java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.UpdateTokenRequest parseDelimitedFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input);
}
public static tech.ydb.proto.topic.YdbTopic.UpdateTokenRequest parseDelimitedFrom(
java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.UpdateTokenRequest parseFrom(
com.google.protobuf.CodedInputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static tech.ydb.proto.topic.YdbTopic.UpdateTokenRequest parseFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry);
}
@java.lang.Override
public Builder newBuilderForType() { return newBuilder(); }
public static Builder newBuilder() {
return DEFAULT_INSTANCE.toBuilder();
}
public static Builder newBuilder(tech.ydb.proto.topic.YdbTopic.UpdateTokenRequest prototype) {
return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
}
@java.lang.Override
public Builder toBuilder() {
return this == DEFAULT_INSTANCE
? new Builder() : new Builder().mergeFrom(this);
}
@java.lang.Override
protected Builder newBuilderForType(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
Builder builder = new Builder(parent);
return builder;
}
/**
*
* In-session reauthentication and reauthorization, lets user increase session lifetime.
* Client should wait for UpdateTokenResponse before sending next UpdateTokenRequest.
*
*
* Protobuf type {@code Ydb.Topic.UpdateTokenRequest}
*/
public static final class Builder extends
com.google.protobuf.GeneratedMessageV3.Builder implements
// @@protoc_insertion_point(builder_implements:Ydb.Topic.UpdateTokenRequest)
tech.ydb.proto.topic.YdbTopic.UpdateTokenRequestOrBuilder {
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_UpdateTokenRequest_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_UpdateTokenRequest_fieldAccessorTable
.ensureFieldAccessorsInitialized(
tech.ydb.proto.topic.YdbTopic.UpdateTokenRequest.class, tech.ydb.proto.topic.YdbTopic.UpdateTokenRequest.Builder.class);
}
// Construct using tech.ydb.proto.topic.YdbTopic.UpdateTokenRequest.newBuilder()
private Builder() {
}
private Builder(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
super(parent);
}
@java.lang.Override
public Builder clear() {
super.clear();
bitField0_ = 0;
token_ = "";
return this;
}
@java.lang.Override
public com.google.protobuf.Descriptors.Descriptor
getDescriptorForType() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_UpdateTokenRequest_descriptor;
}
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.UpdateTokenRequest getDefaultInstanceForType() {
return tech.ydb.proto.topic.YdbTopic.UpdateTokenRequest.getDefaultInstance();
}
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.UpdateTokenRequest build() {
tech.ydb.proto.topic.YdbTopic.UpdateTokenRequest result = buildPartial();
if (!result.isInitialized()) {
throw newUninitializedMessageException(result);
}
return result;
}
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.UpdateTokenRequest buildPartial() {
tech.ydb.proto.topic.YdbTopic.UpdateTokenRequest result = new tech.ydb.proto.topic.YdbTopic.UpdateTokenRequest(this);
if (bitField0_ != 0) { buildPartial0(result); }
onBuilt();
return result;
}
private void buildPartial0(tech.ydb.proto.topic.YdbTopic.UpdateTokenRequest result) {
int from_bitField0_ = bitField0_;
if (((from_bitField0_ & 0x00000001) != 0)) {
result.token_ = token_;
}
}
@java.lang.Override
public Builder clone() {
return super.clone();
}
@java.lang.Override
public Builder setField(
com.google.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) {
return super.setField(field, value);
}
@java.lang.Override
public Builder clearField(
com.google.protobuf.Descriptors.FieldDescriptor field) {
return super.clearField(field);
}
@java.lang.Override
public Builder clearOneof(
com.google.protobuf.Descriptors.OneofDescriptor oneof) {
return super.clearOneof(oneof);
}
@java.lang.Override
public Builder setRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
int index, java.lang.Object value) {
return super.setRepeatedField(field, index, value);
}
@java.lang.Override
public Builder addRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) {
return super.addRepeatedField(field, value);
}
@java.lang.Override
public Builder mergeFrom(com.google.protobuf.Message other) {
if (other instanceof tech.ydb.proto.topic.YdbTopic.UpdateTokenRequest) {
return mergeFrom((tech.ydb.proto.topic.YdbTopic.UpdateTokenRequest)other);
} else {
super.mergeFrom(other);
return this;
}
}
public Builder mergeFrom(tech.ydb.proto.topic.YdbTopic.UpdateTokenRequest other) {
if (other == tech.ydb.proto.topic.YdbTopic.UpdateTokenRequest.getDefaultInstance()) return this;
if (!other.getToken().isEmpty()) {
token_ = other.token_;
bitField0_ |= 0x00000001;
onChanged();
}
this.mergeUnknownFields(other.getUnknownFields());
onChanged();
return this;
}
@java.lang.Override
public final boolean isInitialized() {
return true;
}
@java.lang.Override
public Builder mergeFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
if (extensionRegistry == null) {
throw new java.lang.NullPointerException();
}
try {
boolean done = false;
while (!done) {
int tag = input.readTag();
switch (tag) {
case 0:
done = true;
break;
case 10: {
token_ = input.readStringRequireUtf8();
bitField0_ |= 0x00000001;
break;
} // case 10
default: {
if (!super.parseUnknownField(input, extensionRegistry, tag)) {
done = true; // was an endgroup tag
}
break;
} // default:
} // switch (tag)
} // while (!done)
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.unwrapIOException();
} finally {
onChanged();
} // finally
return this;
}
private int bitField0_;
private java.lang.Object token_ = "";
/**
* string token = 1 [(.Ydb.sensitive) = true];
* @return The token.
*/
public java.lang.String getToken() {
java.lang.Object ref = token_;
if (!(ref instanceof java.lang.String)) {
com.google.protobuf.ByteString bs =
(com.google.protobuf.ByteString) ref;
java.lang.String s = bs.toStringUtf8();
token_ = s;
return s;
} else {
return (java.lang.String) ref;
}
}
/**
* string token = 1 [(.Ydb.sensitive) = true];
* @return The bytes for token.
*/
public com.google.protobuf.ByteString
getTokenBytes() {
java.lang.Object ref = token_;
if (ref instanceof String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
token_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
/**
* string token = 1 [(.Ydb.sensitive) = true];
* @param value The token to set.
* @return This builder for chaining.
*/
public Builder setToken(
java.lang.String value) {
if (value == null) { throw new NullPointerException(); }
token_ = value;
bitField0_ |= 0x00000001;
onChanged();
return this;
}
/**
* string token = 1 [(.Ydb.sensitive) = true];
* @return This builder for chaining.
*/
public Builder clearToken() {
token_ = getDefaultInstance().getToken();
bitField0_ = (bitField0_ & ~0x00000001);
onChanged();
return this;
}
/**
* string token = 1 [(.Ydb.sensitive) = true];
* @param value The bytes for token to set.
* @return This builder for chaining.
*/
public Builder setTokenBytes(
com.google.protobuf.ByteString value) {
if (value == null) { throw new NullPointerException(); }
checkByteStringIsUtf8(value);
token_ = value;
bitField0_ |= 0x00000001;
onChanged();
return this;
}
@java.lang.Override
public final Builder setUnknownFields(
final com.google.protobuf.UnknownFieldSet unknownFields) {
return super.setUnknownFields(unknownFields);
}
@java.lang.Override
public final Builder mergeUnknownFields(
final com.google.protobuf.UnknownFieldSet unknownFields) {
return super.mergeUnknownFields(unknownFields);
}
// @@protoc_insertion_point(builder_scope:Ydb.Topic.UpdateTokenRequest)
}
// @@protoc_insertion_point(class_scope:Ydb.Topic.UpdateTokenRequest)
private static final tech.ydb.proto.topic.YdbTopic.UpdateTokenRequest DEFAULT_INSTANCE;
static {
DEFAULT_INSTANCE = new tech.ydb.proto.topic.YdbTopic.UpdateTokenRequest();
}
public static tech.ydb.proto.topic.YdbTopic.UpdateTokenRequest getDefaultInstance() {
return DEFAULT_INSTANCE;
}
private static final com.google.protobuf.Parser
PARSER = new com.google.protobuf.AbstractParser() {
@java.lang.Override
public UpdateTokenRequest parsePartialFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
Builder builder = newBuilder();
try {
builder.mergeFrom(input, extensionRegistry);
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.setUnfinishedMessage(builder.buildPartial());
} catch (com.google.protobuf.UninitializedMessageException e) {
throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial());
} catch (java.io.IOException e) {
throw new com.google.protobuf.InvalidProtocolBufferException(e)
.setUnfinishedMessage(builder.buildPartial());
}
return builder.buildPartial();
}
};
public static com.google.protobuf.Parser parser() {
return PARSER;
}
@java.lang.Override
public com.google.protobuf.Parser getParserForType() {
return PARSER;
}
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.UpdateTokenRequest getDefaultInstanceForType() {
return DEFAULT_INSTANCE;
}
}
public interface UpdateTokenResponseOrBuilder extends
// @@protoc_insertion_point(interface_extends:Ydb.Topic.UpdateTokenResponse)
com.google.protobuf.MessageOrBuilder {
}
/**
* Protobuf type {@code Ydb.Topic.UpdateTokenResponse}
*/
public static final class UpdateTokenResponse extends
com.google.protobuf.GeneratedMessageV3 implements
// @@protoc_insertion_point(message_implements:Ydb.Topic.UpdateTokenResponse)
UpdateTokenResponseOrBuilder {
private static final long serialVersionUID = 0L;
// Use UpdateTokenResponse.newBuilder() to construct.
private UpdateTokenResponse(com.google.protobuf.GeneratedMessageV3.Builder> builder) {
super(builder);
}
private UpdateTokenResponse() {
}
@java.lang.Override
@SuppressWarnings({"unused"})
protected java.lang.Object newInstance(
UnusedPrivateParameter unused) {
return new UpdateTokenResponse();
}
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_UpdateTokenResponse_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_UpdateTokenResponse_fieldAccessorTable
.ensureFieldAccessorsInitialized(
tech.ydb.proto.topic.YdbTopic.UpdateTokenResponse.class, tech.ydb.proto.topic.YdbTopic.UpdateTokenResponse.Builder.class);
}
private byte memoizedIsInitialized = -1;
@java.lang.Override
public final boolean isInitialized() {
byte isInitialized = memoizedIsInitialized;
if (isInitialized == 1) return true;
if (isInitialized == 0) return false;
memoizedIsInitialized = 1;
return true;
}
@java.lang.Override
public void writeTo(com.google.protobuf.CodedOutputStream output)
throws java.io.IOException {
getUnknownFields().writeTo(output);
}
@java.lang.Override
public int getSerializedSize() {
int size = memoizedSize;
if (size != -1) return size;
size = 0;
size += getUnknownFields().getSerializedSize();
memoizedSize = size;
return size;
}
@java.lang.Override
public boolean equals(final java.lang.Object obj) {
if (obj == this) {
return true;
}
if (!(obj instanceof tech.ydb.proto.topic.YdbTopic.UpdateTokenResponse)) {
return super.equals(obj);
}
tech.ydb.proto.topic.YdbTopic.UpdateTokenResponse other = (tech.ydb.proto.topic.YdbTopic.UpdateTokenResponse) obj;
if (!getUnknownFields().equals(other.getUnknownFields())) return false;
return true;
}
@java.lang.Override
public int hashCode() {
if (memoizedHashCode != 0) {
return memoizedHashCode;
}
int hash = 41;
hash = (19 * hash) + getDescriptor().hashCode();
hash = (29 * hash) + getUnknownFields().hashCode();
memoizedHashCode = hash;
return hash;
}
public static tech.ydb.proto.topic.YdbTopic.UpdateTokenResponse parseFrom(
java.nio.ByteBuffer data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static tech.ydb.proto.topic.YdbTopic.UpdateTokenResponse parseFrom(
java.nio.ByteBuffer data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.UpdateTokenResponse parseFrom(
com.google.protobuf.ByteString data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static tech.ydb.proto.topic.YdbTopic.UpdateTokenResponse parseFrom(
com.google.protobuf.ByteString data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.UpdateTokenResponse parseFrom(byte[] data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static tech.ydb.proto.topic.YdbTopic.UpdateTokenResponse parseFrom(
byte[] data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.UpdateTokenResponse parseFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static tech.ydb.proto.topic.YdbTopic.UpdateTokenResponse parseFrom(
java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.UpdateTokenResponse parseDelimitedFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input);
}
public static tech.ydb.proto.topic.YdbTopic.UpdateTokenResponse parseDelimitedFrom(
java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.UpdateTokenResponse parseFrom(
com.google.protobuf.CodedInputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static tech.ydb.proto.topic.YdbTopic.UpdateTokenResponse parseFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry);
}
@java.lang.Override
public Builder newBuilderForType() { return newBuilder(); }
public static Builder newBuilder() {
return DEFAULT_INSTANCE.toBuilder();
}
public static Builder newBuilder(tech.ydb.proto.topic.YdbTopic.UpdateTokenResponse prototype) {
return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
}
@java.lang.Override
public Builder toBuilder() {
return this == DEFAULT_INSTANCE
? new Builder() : new Builder().mergeFrom(this);
}
@java.lang.Override
protected Builder newBuilderForType(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
Builder builder = new Builder(parent);
return builder;
}
/**
* Protobuf type {@code Ydb.Topic.UpdateTokenResponse}
*/
public static final class Builder extends
com.google.protobuf.GeneratedMessageV3.Builder implements
// @@protoc_insertion_point(builder_implements:Ydb.Topic.UpdateTokenResponse)
tech.ydb.proto.topic.YdbTopic.UpdateTokenResponseOrBuilder {
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_UpdateTokenResponse_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_UpdateTokenResponse_fieldAccessorTable
.ensureFieldAccessorsInitialized(
tech.ydb.proto.topic.YdbTopic.UpdateTokenResponse.class, tech.ydb.proto.topic.YdbTopic.UpdateTokenResponse.Builder.class);
}
// Construct using tech.ydb.proto.topic.YdbTopic.UpdateTokenResponse.newBuilder()
private Builder() {
}
private Builder(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
super(parent);
}
@java.lang.Override
public Builder clear() {
super.clear();
return this;
}
@java.lang.Override
public com.google.protobuf.Descriptors.Descriptor
getDescriptorForType() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_UpdateTokenResponse_descriptor;
}
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.UpdateTokenResponse getDefaultInstanceForType() {
return tech.ydb.proto.topic.YdbTopic.UpdateTokenResponse.getDefaultInstance();
}
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.UpdateTokenResponse build() {
tech.ydb.proto.topic.YdbTopic.UpdateTokenResponse result = buildPartial();
if (!result.isInitialized()) {
throw newUninitializedMessageException(result);
}
return result;
}
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.UpdateTokenResponse buildPartial() {
tech.ydb.proto.topic.YdbTopic.UpdateTokenResponse result = new tech.ydb.proto.topic.YdbTopic.UpdateTokenResponse(this);
onBuilt();
return result;
}
@java.lang.Override
public Builder clone() {
return super.clone();
}
@java.lang.Override
public Builder setField(
com.google.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) {
return super.setField(field, value);
}
@java.lang.Override
public Builder clearField(
com.google.protobuf.Descriptors.FieldDescriptor field) {
return super.clearField(field);
}
@java.lang.Override
public Builder clearOneof(
com.google.protobuf.Descriptors.OneofDescriptor oneof) {
return super.clearOneof(oneof);
}
@java.lang.Override
public Builder setRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
int index, java.lang.Object value) {
return super.setRepeatedField(field, index, value);
}
@java.lang.Override
public Builder addRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) {
return super.addRepeatedField(field, value);
}
@java.lang.Override
public Builder mergeFrom(com.google.protobuf.Message other) {
if (other instanceof tech.ydb.proto.topic.YdbTopic.UpdateTokenResponse) {
return mergeFrom((tech.ydb.proto.topic.YdbTopic.UpdateTokenResponse)other);
} else {
super.mergeFrom(other);
return this;
}
}
public Builder mergeFrom(tech.ydb.proto.topic.YdbTopic.UpdateTokenResponse other) {
if (other == tech.ydb.proto.topic.YdbTopic.UpdateTokenResponse.getDefaultInstance()) return this;
this.mergeUnknownFields(other.getUnknownFields());
onChanged();
return this;
}
@java.lang.Override
public final boolean isInitialized() {
return true;
}
@java.lang.Override
public Builder mergeFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
if (extensionRegistry == null) {
throw new java.lang.NullPointerException();
}
try {
boolean done = false;
while (!done) {
int tag = input.readTag();
switch (tag) {
case 0:
done = true;
break;
default: {
if (!super.parseUnknownField(input, extensionRegistry, tag)) {
done = true; // was an endgroup tag
}
break;
} // default:
} // switch (tag)
} // while (!done)
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.unwrapIOException();
} finally {
onChanged();
} // finally
return this;
}
@java.lang.Override
public final Builder setUnknownFields(
final com.google.protobuf.UnknownFieldSet unknownFields) {
return super.setUnknownFields(unknownFields);
}
@java.lang.Override
public final Builder mergeUnknownFields(
final com.google.protobuf.UnknownFieldSet unknownFields) {
return super.mergeUnknownFields(unknownFields);
}
// @@protoc_insertion_point(builder_scope:Ydb.Topic.UpdateTokenResponse)
}
// @@protoc_insertion_point(class_scope:Ydb.Topic.UpdateTokenResponse)
private static final tech.ydb.proto.topic.YdbTopic.UpdateTokenResponse DEFAULT_INSTANCE;
static {
DEFAULT_INSTANCE = new tech.ydb.proto.topic.YdbTopic.UpdateTokenResponse();
}
public static tech.ydb.proto.topic.YdbTopic.UpdateTokenResponse getDefaultInstance() {
return DEFAULT_INSTANCE;
}
private static final com.google.protobuf.Parser
PARSER = new com.google.protobuf.AbstractParser() {
@java.lang.Override
public UpdateTokenResponse parsePartialFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
Builder builder = newBuilder();
try {
builder.mergeFrom(input, extensionRegistry);
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.setUnfinishedMessage(builder.buildPartial());
} catch (com.google.protobuf.UninitializedMessageException e) {
throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial());
} catch (java.io.IOException e) {
throw new com.google.protobuf.InvalidProtocolBufferException(e)
.setUnfinishedMessage(builder.buildPartial());
}
return builder.buildPartial();
}
};
public static com.google.protobuf.Parser parser() {
return PARSER;
}
@java.lang.Override
public com.google.protobuf.Parser getParserForType() {
return PARSER;
}
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.UpdateTokenResponse getDefaultInstanceForType() {
return DEFAULT_INSTANCE;
}
}
public interface PartitionWithGenerationOrBuilder extends
// @@protoc_insertion_point(interface_extends:Ydb.Topic.PartitionWithGeneration)
com.google.protobuf.MessageOrBuilder {
/**
*
* Partition identifier.
*
*
* int64 partition_id = 1;
* @return The partitionId.
*/
long getPartitionId();
/**
*
* Partition generation.
*
*
* int64 generation = 2;
* @return The generation.
*/
long getGeneration();
}
/**
* Protobuf type {@code Ydb.Topic.PartitionWithGeneration}
*/
public static final class PartitionWithGeneration extends
com.google.protobuf.GeneratedMessageV3 implements
// @@protoc_insertion_point(message_implements:Ydb.Topic.PartitionWithGeneration)
PartitionWithGenerationOrBuilder {
private static final long serialVersionUID = 0L;
// Use PartitionWithGeneration.newBuilder() to construct.
private PartitionWithGeneration(com.google.protobuf.GeneratedMessageV3.Builder> builder) {
super(builder);
}
private PartitionWithGeneration() {
}
@java.lang.Override
@SuppressWarnings({"unused"})
protected java.lang.Object newInstance(
UnusedPrivateParameter unused) {
return new PartitionWithGeneration();
}
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_PartitionWithGeneration_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_PartitionWithGeneration_fieldAccessorTable
.ensureFieldAccessorsInitialized(
tech.ydb.proto.topic.YdbTopic.PartitionWithGeneration.class, tech.ydb.proto.topic.YdbTopic.PartitionWithGeneration.Builder.class);
}
public static final int PARTITION_ID_FIELD_NUMBER = 1;
private long partitionId_ = 0L;
/**
*
* Partition identifier.
*
*
* int64 partition_id = 1;
* @return The partitionId.
*/
@java.lang.Override
public long getPartitionId() {
return partitionId_;
}
public static final int GENERATION_FIELD_NUMBER = 2;
private long generation_ = 0L;
/**
*
* Partition generation.
*
*
* int64 generation = 2;
* @return The generation.
*/
@java.lang.Override
public long getGeneration() {
return generation_;
}
private byte memoizedIsInitialized = -1;
@java.lang.Override
public final boolean isInitialized() {
byte isInitialized = memoizedIsInitialized;
if (isInitialized == 1) return true;
if (isInitialized == 0) return false;
memoizedIsInitialized = 1;
return true;
}
@java.lang.Override
public void writeTo(com.google.protobuf.CodedOutputStream output)
throws java.io.IOException {
if (partitionId_ != 0L) {
output.writeInt64(1, partitionId_);
}
if (generation_ != 0L) {
output.writeInt64(2, generation_);
}
getUnknownFields().writeTo(output);
}
@java.lang.Override
public int getSerializedSize() {
int size = memoizedSize;
if (size != -1) return size;
size = 0;
if (partitionId_ != 0L) {
size += com.google.protobuf.CodedOutputStream
.computeInt64Size(1, partitionId_);
}
if (generation_ != 0L) {
size += com.google.protobuf.CodedOutputStream
.computeInt64Size(2, generation_);
}
size += getUnknownFields().getSerializedSize();
memoizedSize = size;
return size;
}
@java.lang.Override
public boolean equals(final java.lang.Object obj) {
if (obj == this) {
return true;
}
if (!(obj instanceof tech.ydb.proto.topic.YdbTopic.PartitionWithGeneration)) {
return super.equals(obj);
}
tech.ydb.proto.topic.YdbTopic.PartitionWithGeneration other = (tech.ydb.proto.topic.YdbTopic.PartitionWithGeneration) obj;
if (getPartitionId()
!= other.getPartitionId()) return false;
if (getGeneration()
!= other.getGeneration()) return false;
if (!getUnknownFields().equals(other.getUnknownFields())) return false;
return true;
}
@java.lang.Override
public int hashCode() {
if (memoizedHashCode != 0) {
return memoizedHashCode;
}
int hash = 41;
hash = (19 * hash) + getDescriptor().hashCode();
hash = (37 * hash) + PARTITION_ID_FIELD_NUMBER;
hash = (53 * hash) + com.google.protobuf.Internal.hashLong(
getPartitionId());
hash = (37 * hash) + GENERATION_FIELD_NUMBER;
hash = (53 * hash) + com.google.protobuf.Internal.hashLong(
getGeneration());
hash = (29 * hash) + getUnknownFields().hashCode();
memoizedHashCode = hash;
return hash;
}
public static tech.ydb.proto.topic.YdbTopic.PartitionWithGeneration parseFrom(
java.nio.ByteBuffer data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static tech.ydb.proto.topic.YdbTopic.PartitionWithGeneration parseFrom(
java.nio.ByteBuffer data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.PartitionWithGeneration parseFrom(
com.google.protobuf.ByteString data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static tech.ydb.proto.topic.YdbTopic.PartitionWithGeneration parseFrom(
com.google.protobuf.ByteString data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.PartitionWithGeneration parseFrom(byte[] data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static tech.ydb.proto.topic.YdbTopic.PartitionWithGeneration parseFrom(
byte[] data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.PartitionWithGeneration parseFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static tech.ydb.proto.topic.YdbTopic.PartitionWithGeneration parseFrom(
java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.PartitionWithGeneration parseDelimitedFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input);
}
public static tech.ydb.proto.topic.YdbTopic.PartitionWithGeneration parseDelimitedFrom(
java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.PartitionWithGeneration parseFrom(
com.google.protobuf.CodedInputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static tech.ydb.proto.topic.YdbTopic.PartitionWithGeneration parseFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry);
}
@java.lang.Override
public Builder newBuilderForType() { return newBuilder(); }
public static Builder newBuilder() {
return DEFAULT_INSTANCE.toBuilder();
}
public static Builder newBuilder(tech.ydb.proto.topic.YdbTopic.PartitionWithGeneration prototype) {
return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
}
@java.lang.Override
public Builder toBuilder() {
return this == DEFAULT_INSTANCE
? new Builder() : new Builder().mergeFrom(this);
}
@java.lang.Override
protected Builder newBuilderForType(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
Builder builder = new Builder(parent);
return builder;
}
/**
* Protobuf type {@code Ydb.Topic.PartitionWithGeneration}
*/
public static final class Builder extends
com.google.protobuf.GeneratedMessageV3.Builder implements
// @@protoc_insertion_point(builder_implements:Ydb.Topic.PartitionWithGeneration)
tech.ydb.proto.topic.YdbTopic.PartitionWithGenerationOrBuilder {
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_PartitionWithGeneration_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_PartitionWithGeneration_fieldAccessorTable
.ensureFieldAccessorsInitialized(
tech.ydb.proto.topic.YdbTopic.PartitionWithGeneration.class, tech.ydb.proto.topic.YdbTopic.PartitionWithGeneration.Builder.class);
}
// Construct using tech.ydb.proto.topic.YdbTopic.PartitionWithGeneration.newBuilder()
private Builder() {
}
private Builder(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
super(parent);
}
@java.lang.Override
public Builder clear() {
super.clear();
bitField0_ = 0;
partitionId_ = 0L;
generation_ = 0L;
return this;
}
@java.lang.Override
public com.google.protobuf.Descriptors.Descriptor
getDescriptorForType() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_PartitionWithGeneration_descriptor;
}
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.PartitionWithGeneration getDefaultInstanceForType() {
return tech.ydb.proto.topic.YdbTopic.PartitionWithGeneration.getDefaultInstance();
}
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.PartitionWithGeneration build() {
tech.ydb.proto.topic.YdbTopic.PartitionWithGeneration result = buildPartial();
if (!result.isInitialized()) {
throw newUninitializedMessageException(result);
}
return result;
}
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.PartitionWithGeneration buildPartial() {
tech.ydb.proto.topic.YdbTopic.PartitionWithGeneration result = new tech.ydb.proto.topic.YdbTopic.PartitionWithGeneration(this);
if (bitField0_ != 0) { buildPartial0(result); }
onBuilt();
return result;
}
private void buildPartial0(tech.ydb.proto.topic.YdbTopic.PartitionWithGeneration result) {
int from_bitField0_ = bitField0_;
if (((from_bitField0_ & 0x00000001) != 0)) {
result.partitionId_ = partitionId_;
}
if (((from_bitField0_ & 0x00000002) != 0)) {
result.generation_ = generation_;
}
}
@java.lang.Override
public Builder clone() {
return super.clone();
}
@java.lang.Override
public Builder setField(
com.google.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) {
return super.setField(field, value);
}
@java.lang.Override
public Builder clearField(
com.google.protobuf.Descriptors.FieldDescriptor field) {
return super.clearField(field);
}
@java.lang.Override
public Builder clearOneof(
com.google.protobuf.Descriptors.OneofDescriptor oneof) {
return super.clearOneof(oneof);
}
@java.lang.Override
public Builder setRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
int index, java.lang.Object value) {
return super.setRepeatedField(field, index, value);
}
@java.lang.Override
public Builder addRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) {
return super.addRepeatedField(field, value);
}
@java.lang.Override
public Builder mergeFrom(com.google.protobuf.Message other) {
if (other instanceof tech.ydb.proto.topic.YdbTopic.PartitionWithGeneration) {
return mergeFrom((tech.ydb.proto.topic.YdbTopic.PartitionWithGeneration)other);
} else {
super.mergeFrom(other);
return this;
}
}
public Builder mergeFrom(tech.ydb.proto.topic.YdbTopic.PartitionWithGeneration other) {
if (other == tech.ydb.proto.topic.YdbTopic.PartitionWithGeneration.getDefaultInstance()) return this;
if (other.getPartitionId() != 0L) {
setPartitionId(other.getPartitionId());
}
if (other.getGeneration() != 0L) {
setGeneration(other.getGeneration());
}
this.mergeUnknownFields(other.getUnknownFields());
onChanged();
return this;
}
@java.lang.Override
public final boolean isInitialized() {
return true;
}
@java.lang.Override
public Builder mergeFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
if (extensionRegistry == null) {
throw new java.lang.NullPointerException();
}
try {
boolean done = false;
while (!done) {
int tag = input.readTag();
switch (tag) {
case 0:
done = true;
break;
case 8: {
partitionId_ = input.readInt64();
bitField0_ |= 0x00000001;
break;
} // case 8
case 16: {
generation_ = input.readInt64();
bitField0_ |= 0x00000002;
break;
} // case 16
default: {
if (!super.parseUnknownField(input, extensionRegistry, tag)) {
done = true; // was an endgroup tag
}
break;
} // default:
} // switch (tag)
} // while (!done)
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.unwrapIOException();
} finally {
onChanged();
} // finally
return this;
}
private int bitField0_;
private long partitionId_ ;
/**
*
* Partition identifier.
*
*
* int64 partition_id = 1;
* @return The partitionId.
*/
@java.lang.Override
public long getPartitionId() {
return partitionId_;
}
/**
*
* Partition identifier.
*
*
* int64 partition_id = 1;
* @param value The partitionId to set.
* @return This builder for chaining.
*/
public Builder setPartitionId(long value) {
partitionId_ = value;
bitField0_ |= 0x00000001;
onChanged();
return this;
}
/**
*
* Partition identifier.
*
*
* int64 partition_id = 1;
* @return This builder for chaining.
*/
public Builder clearPartitionId() {
bitField0_ = (bitField0_ & ~0x00000001);
partitionId_ = 0L;
onChanged();
return this;
}
private long generation_ ;
/**
*
* Partition generation.
*
*
* int64 generation = 2;
* @return The generation.
*/
@java.lang.Override
public long getGeneration() {
return generation_;
}
/**
*
* Partition generation.
*
*
* int64 generation = 2;
* @param value The generation to set.
* @return This builder for chaining.
*/
public Builder setGeneration(long value) {
generation_ = value;
bitField0_ |= 0x00000002;
onChanged();
return this;
}
/**
*
* Partition generation.
*
*
* int64 generation = 2;
* @return This builder for chaining.
*/
public Builder clearGeneration() {
bitField0_ = (bitField0_ & ~0x00000002);
generation_ = 0L;
onChanged();
return this;
}
@java.lang.Override
public final Builder setUnknownFields(
final com.google.protobuf.UnknownFieldSet unknownFields) {
return super.setUnknownFields(unknownFields);
}
@java.lang.Override
public final Builder mergeUnknownFields(
final com.google.protobuf.UnknownFieldSet unknownFields) {
return super.mergeUnknownFields(unknownFields);
}
// @@protoc_insertion_point(builder_scope:Ydb.Topic.PartitionWithGeneration)
}
// @@protoc_insertion_point(class_scope:Ydb.Topic.PartitionWithGeneration)
private static final tech.ydb.proto.topic.YdbTopic.PartitionWithGeneration DEFAULT_INSTANCE;
static {
DEFAULT_INSTANCE = new tech.ydb.proto.topic.YdbTopic.PartitionWithGeneration();
}
public static tech.ydb.proto.topic.YdbTopic.PartitionWithGeneration getDefaultInstance() {
return DEFAULT_INSTANCE;
}
private static final com.google.protobuf.Parser
PARSER = new com.google.protobuf.AbstractParser() {
@java.lang.Override
public PartitionWithGeneration parsePartialFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
Builder builder = newBuilder();
try {
builder.mergeFrom(input, extensionRegistry);
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.setUnfinishedMessage(builder.buildPartial());
} catch (com.google.protobuf.UninitializedMessageException e) {
throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial());
} catch (java.io.IOException e) {
throw new com.google.protobuf.InvalidProtocolBufferException(e)
.setUnfinishedMessage(builder.buildPartial());
}
return builder.buildPartial();
}
};
public static com.google.protobuf.Parser parser() {
return PARSER;
}
@java.lang.Override
public com.google.protobuf.Parser getParserForType() {
return PARSER;
}
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.PartitionWithGeneration getDefaultInstanceForType() {
return DEFAULT_INSTANCE;
}
}
public interface MetadataItemOrBuilder extends
// @@protoc_insertion_point(interface_extends:Ydb.Topic.MetadataItem)
com.google.protobuf.MessageOrBuilder {
/**
* string key = 1;
* @return The key.
*/
java.lang.String getKey();
/**
* string key = 1;
* @return The bytes for key.
*/
com.google.protobuf.ByteString
getKeyBytes();
/**
* bytes value = 2;
* @return The value.
*/
com.google.protobuf.ByteString getValue();
}
/**
* Protobuf type {@code Ydb.Topic.MetadataItem}
*/
public static final class MetadataItem extends
com.google.protobuf.GeneratedMessageV3 implements
// @@protoc_insertion_point(message_implements:Ydb.Topic.MetadataItem)
MetadataItemOrBuilder {
private static final long serialVersionUID = 0L;
// Use MetadataItem.newBuilder() to construct.
private MetadataItem(com.google.protobuf.GeneratedMessageV3.Builder> builder) {
super(builder);
}
private MetadataItem() {
key_ = "";
value_ = com.google.protobuf.ByteString.EMPTY;
}
@java.lang.Override
@SuppressWarnings({"unused"})
protected java.lang.Object newInstance(
UnusedPrivateParameter unused) {
return new MetadataItem();
}
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_MetadataItem_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_MetadataItem_fieldAccessorTable
.ensureFieldAccessorsInitialized(
tech.ydb.proto.topic.YdbTopic.MetadataItem.class, tech.ydb.proto.topic.YdbTopic.MetadataItem.Builder.class);
}
public static final int KEY_FIELD_NUMBER = 1;
@SuppressWarnings("serial")
private volatile java.lang.Object key_ = "";
/**
* string key = 1;
* @return The key.
*/
@java.lang.Override
public java.lang.String getKey() {
java.lang.Object ref = key_;
if (ref instanceof java.lang.String) {
return (java.lang.String) ref;
} else {
com.google.protobuf.ByteString bs =
(com.google.protobuf.ByteString) ref;
java.lang.String s = bs.toStringUtf8();
key_ = s;
return s;
}
}
/**
* string key = 1;
* @return The bytes for key.
*/
@java.lang.Override
public com.google.protobuf.ByteString
getKeyBytes() {
java.lang.Object ref = key_;
if (ref instanceof java.lang.String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
key_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
public static final int VALUE_FIELD_NUMBER = 2;
private com.google.protobuf.ByteString value_ = com.google.protobuf.ByteString.EMPTY;
/**
* bytes value = 2;
* @return The value.
*/
@java.lang.Override
public com.google.protobuf.ByteString getValue() {
return value_;
}
private byte memoizedIsInitialized = -1;
@java.lang.Override
public final boolean isInitialized() {
byte isInitialized = memoizedIsInitialized;
if (isInitialized == 1) return true;
if (isInitialized == 0) return false;
memoizedIsInitialized = 1;
return true;
}
@java.lang.Override
public void writeTo(com.google.protobuf.CodedOutputStream output)
throws java.io.IOException {
if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(key_)) {
com.google.protobuf.GeneratedMessageV3.writeString(output, 1, key_);
}
if (!value_.isEmpty()) {
output.writeBytes(2, value_);
}
getUnknownFields().writeTo(output);
}
@java.lang.Override
public int getSerializedSize() {
int size = memoizedSize;
if (size != -1) return size;
size = 0;
if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(key_)) {
size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, key_);
}
if (!value_.isEmpty()) {
size += com.google.protobuf.CodedOutputStream
.computeBytesSize(2, value_);
}
size += getUnknownFields().getSerializedSize();
memoizedSize = size;
return size;
}
@java.lang.Override
public boolean equals(final java.lang.Object obj) {
if (obj == this) {
return true;
}
if (!(obj instanceof tech.ydb.proto.topic.YdbTopic.MetadataItem)) {
return super.equals(obj);
}
tech.ydb.proto.topic.YdbTopic.MetadataItem other = (tech.ydb.proto.topic.YdbTopic.MetadataItem) obj;
if (!getKey()
.equals(other.getKey())) return false;
if (!getValue()
.equals(other.getValue())) return false;
if (!getUnknownFields().equals(other.getUnknownFields())) return false;
return true;
}
@java.lang.Override
public int hashCode() {
if (memoizedHashCode != 0) {
return memoizedHashCode;
}
int hash = 41;
hash = (19 * hash) + getDescriptor().hashCode();
hash = (37 * hash) + KEY_FIELD_NUMBER;
hash = (53 * hash) + getKey().hashCode();
hash = (37 * hash) + VALUE_FIELD_NUMBER;
hash = (53 * hash) + getValue().hashCode();
hash = (29 * hash) + getUnknownFields().hashCode();
memoizedHashCode = hash;
return hash;
}
public static tech.ydb.proto.topic.YdbTopic.MetadataItem parseFrom(
java.nio.ByteBuffer data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static tech.ydb.proto.topic.YdbTopic.MetadataItem parseFrom(
java.nio.ByteBuffer data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.MetadataItem parseFrom(
com.google.protobuf.ByteString data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static tech.ydb.proto.topic.YdbTopic.MetadataItem parseFrom(
com.google.protobuf.ByteString data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.MetadataItem parseFrom(byte[] data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static tech.ydb.proto.topic.YdbTopic.MetadataItem parseFrom(
byte[] data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.MetadataItem parseFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static tech.ydb.proto.topic.YdbTopic.MetadataItem parseFrom(
java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.MetadataItem parseDelimitedFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input);
}
public static tech.ydb.proto.topic.YdbTopic.MetadataItem parseDelimitedFrom(
java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.MetadataItem parseFrom(
com.google.protobuf.CodedInputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static tech.ydb.proto.topic.YdbTopic.MetadataItem parseFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry);
}
@java.lang.Override
public Builder newBuilderForType() { return newBuilder(); }
public static Builder newBuilder() {
return DEFAULT_INSTANCE.toBuilder();
}
public static Builder newBuilder(tech.ydb.proto.topic.YdbTopic.MetadataItem prototype) {
return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
}
@java.lang.Override
public Builder toBuilder() {
return this == DEFAULT_INSTANCE
? new Builder() : new Builder().mergeFrom(this);
}
@java.lang.Override
protected Builder newBuilderForType(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
Builder builder = new Builder(parent);
return builder;
}
/**
* Protobuf type {@code Ydb.Topic.MetadataItem}
*/
public static final class Builder extends
com.google.protobuf.GeneratedMessageV3.Builder implements
// @@protoc_insertion_point(builder_implements:Ydb.Topic.MetadataItem)
tech.ydb.proto.topic.YdbTopic.MetadataItemOrBuilder {
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_MetadataItem_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_MetadataItem_fieldAccessorTable
.ensureFieldAccessorsInitialized(
tech.ydb.proto.topic.YdbTopic.MetadataItem.class, tech.ydb.proto.topic.YdbTopic.MetadataItem.Builder.class);
}
// Construct using tech.ydb.proto.topic.YdbTopic.MetadataItem.newBuilder()
private Builder() {
}
private Builder(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
super(parent);
}
@java.lang.Override
public Builder clear() {
super.clear();
bitField0_ = 0;
key_ = "";
value_ = com.google.protobuf.ByteString.EMPTY;
return this;
}
@java.lang.Override
public com.google.protobuf.Descriptors.Descriptor
getDescriptorForType() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_MetadataItem_descriptor;
}
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.MetadataItem getDefaultInstanceForType() {
return tech.ydb.proto.topic.YdbTopic.MetadataItem.getDefaultInstance();
}
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.MetadataItem build() {
tech.ydb.proto.topic.YdbTopic.MetadataItem result = buildPartial();
if (!result.isInitialized()) {
throw newUninitializedMessageException(result);
}
return result;
}
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.MetadataItem buildPartial() {
tech.ydb.proto.topic.YdbTopic.MetadataItem result = new tech.ydb.proto.topic.YdbTopic.MetadataItem(this);
if (bitField0_ != 0) { buildPartial0(result); }
onBuilt();
return result;
}
private void buildPartial0(tech.ydb.proto.topic.YdbTopic.MetadataItem result) {
int from_bitField0_ = bitField0_;
if (((from_bitField0_ & 0x00000001) != 0)) {
result.key_ = key_;
}
if (((from_bitField0_ & 0x00000002) != 0)) {
result.value_ = value_;
}
}
@java.lang.Override
public Builder clone() {
return super.clone();
}
@java.lang.Override
public Builder setField(
com.google.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) {
return super.setField(field, value);
}
@java.lang.Override
public Builder clearField(
com.google.protobuf.Descriptors.FieldDescriptor field) {
return super.clearField(field);
}
@java.lang.Override
public Builder clearOneof(
com.google.protobuf.Descriptors.OneofDescriptor oneof) {
return super.clearOneof(oneof);
}
@java.lang.Override
public Builder setRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
int index, java.lang.Object value) {
return super.setRepeatedField(field, index, value);
}
@java.lang.Override
public Builder addRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) {
return super.addRepeatedField(field, value);
}
@java.lang.Override
public Builder mergeFrom(com.google.protobuf.Message other) {
if (other instanceof tech.ydb.proto.topic.YdbTopic.MetadataItem) {
return mergeFrom((tech.ydb.proto.topic.YdbTopic.MetadataItem)other);
} else {
super.mergeFrom(other);
return this;
}
}
public Builder mergeFrom(tech.ydb.proto.topic.YdbTopic.MetadataItem other) {
if (other == tech.ydb.proto.topic.YdbTopic.MetadataItem.getDefaultInstance()) return this;
if (!other.getKey().isEmpty()) {
key_ = other.key_;
bitField0_ |= 0x00000001;
onChanged();
}
if (other.getValue() != com.google.protobuf.ByteString.EMPTY) {
setValue(other.getValue());
}
this.mergeUnknownFields(other.getUnknownFields());
onChanged();
return this;
}
@java.lang.Override
public final boolean isInitialized() {
return true;
}
@java.lang.Override
public Builder mergeFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
if (extensionRegistry == null) {
throw new java.lang.NullPointerException();
}
try {
boolean done = false;
while (!done) {
int tag = input.readTag();
switch (tag) {
case 0:
done = true;
break;
case 10: {
key_ = input.readStringRequireUtf8();
bitField0_ |= 0x00000001;
break;
} // case 10
case 18: {
value_ = input.readBytes();
bitField0_ |= 0x00000002;
break;
} // case 18
default: {
if (!super.parseUnknownField(input, extensionRegistry, tag)) {
done = true; // was an endgroup tag
}
break;
} // default:
} // switch (tag)
} // while (!done)
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.unwrapIOException();
} finally {
onChanged();
} // finally
return this;
}
private int bitField0_;
private java.lang.Object key_ = "";
/**
* string key = 1;
* @return The key.
*/
public java.lang.String getKey() {
java.lang.Object ref = key_;
if (!(ref instanceof java.lang.String)) {
com.google.protobuf.ByteString bs =
(com.google.protobuf.ByteString) ref;
java.lang.String s = bs.toStringUtf8();
key_ = s;
return s;
} else {
return (java.lang.String) ref;
}
}
/**
* string key = 1;
* @return The bytes for key.
*/
public com.google.protobuf.ByteString
getKeyBytes() {
java.lang.Object ref = key_;
if (ref instanceof String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
key_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
/**
* string key = 1;
* @param value The key to set.
* @return This builder for chaining.
*/
public Builder setKey(
java.lang.String value) {
if (value == null) { throw new NullPointerException(); }
key_ = value;
bitField0_ |= 0x00000001;
onChanged();
return this;
}
/**
* string key = 1;
* @return This builder for chaining.
*/
public Builder clearKey() {
key_ = getDefaultInstance().getKey();
bitField0_ = (bitField0_ & ~0x00000001);
onChanged();
return this;
}
/**
* string key = 1;
* @param value The bytes for key to set.
* @return This builder for chaining.
*/
public Builder setKeyBytes(
com.google.protobuf.ByteString value) {
if (value == null) { throw new NullPointerException(); }
checkByteStringIsUtf8(value);
key_ = value;
bitField0_ |= 0x00000001;
onChanged();
return this;
}
private com.google.protobuf.ByteString value_ = com.google.protobuf.ByteString.EMPTY;
/**
* bytes value = 2;
* @return The value.
*/
@java.lang.Override
public com.google.protobuf.ByteString getValue() {
return value_;
}
/**
* bytes value = 2;
* @param value The value to set.
* @return This builder for chaining.
*/
public Builder setValue(com.google.protobuf.ByteString value) {
if (value == null) { throw new NullPointerException(); }
value_ = value;
bitField0_ |= 0x00000002;
onChanged();
return this;
}
/**
* bytes value = 2;
* @return This builder for chaining.
*/
public Builder clearValue() {
bitField0_ = (bitField0_ & ~0x00000002);
value_ = getDefaultInstance().getValue();
onChanged();
return this;
}
@java.lang.Override
public final Builder setUnknownFields(
final com.google.protobuf.UnknownFieldSet unknownFields) {
return super.setUnknownFields(unknownFields);
}
@java.lang.Override
public final Builder mergeUnknownFields(
final com.google.protobuf.UnknownFieldSet unknownFields) {
return super.mergeUnknownFields(unknownFields);
}
// @@protoc_insertion_point(builder_scope:Ydb.Topic.MetadataItem)
}
// @@protoc_insertion_point(class_scope:Ydb.Topic.MetadataItem)
private static final tech.ydb.proto.topic.YdbTopic.MetadataItem DEFAULT_INSTANCE;
static {
DEFAULT_INSTANCE = new tech.ydb.proto.topic.YdbTopic.MetadataItem();
}
public static tech.ydb.proto.topic.YdbTopic.MetadataItem getDefaultInstance() {
return DEFAULT_INSTANCE;
}
private static final com.google.protobuf.Parser
PARSER = new com.google.protobuf.AbstractParser() {
@java.lang.Override
public MetadataItem parsePartialFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
Builder builder = newBuilder();
try {
builder.mergeFrom(input, extensionRegistry);
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.setUnfinishedMessage(builder.buildPartial());
} catch (com.google.protobuf.UninitializedMessageException e) {
throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial());
} catch (java.io.IOException e) {
throw new com.google.protobuf.InvalidProtocolBufferException(e)
.setUnfinishedMessage(builder.buildPartial());
}
return builder.buildPartial();
}
};
public static com.google.protobuf.Parser parser() {
return PARSER;
}
@java.lang.Override
public com.google.protobuf.Parser getParserForType() {
return PARSER;
}
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.MetadataItem getDefaultInstanceForType() {
return DEFAULT_INSTANCE;
}
}
public interface StreamWriteMessageOrBuilder extends
// @@protoc_insertion_point(interface_extends:Ydb.Topic.StreamWriteMessage)
com.google.protobuf.MessageOrBuilder {
}
/**
*
* Messages for bidirectional streaming rpc StreamWrite
*
*
* Protobuf type {@code Ydb.Topic.StreamWriteMessage}
*/
public static final class StreamWriteMessage extends
com.google.protobuf.GeneratedMessageV3 implements
// @@protoc_insertion_point(message_implements:Ydb.Topic.StreamWriteMessage)
StreamWriteMessageOrBuilder {
private static final long serialVersionUID = 0L;
// Use StreamWriteMessage.newBuilder() to construct.
private StreamWriteMessage(com.google.protobuf.GeneratedMessageV3.Builder> builder) {
super(builder);
}
private StreamWriteMessage() {
}
@java.lang.Override
@SuppressWarnings({"unused"})
protected java.lang.Object newInstance(
UnusedPrivateParameter unused) {
return new StreamWriteMessage();
}
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_StreamWriteMessage_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_StreamWriteMessage_fieldAccessorTable
.ensureFieldAccessorsInitialized(
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.class, tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.Builder.class);
}
public interface FromClientOrBuilder extends
// @@protoc_insertion_point(interface_extends:Ydb.Topic.StreamWriteMessage.FromClient)
com.google.protobuf.MessageOrBuilder {
/**
* .Ydb.Topic.StreamWriteMessage.InitRequest init_request = 1;
* @return Whether the initRequest field is set.
*/
boolean hasInitRequest();
/**
* .Ydb.Topic.StreamWriteMessage.InitRequest init_request = 1;
* @return The initRequest.
*/
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitRequest getInitRequest();
/**
* .Ydb.Topic.StreamWriteMessage.InitRequest init_request = 1;
*/
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitRequestOrBuilder getInitRequestOrBuilder();
/**
* .Ydb.Topic.StreamWriteMessage.WriteRequest write_request = 2;
* @return Whether the writeRequest field is set.
*/
boolean hasWriteRequest();
/**
* .Ydb.Topic.StreamWriteMessage.WriteRequest write_request = 2;
* @return The writeRequest.
*/
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest getWriteRequest();
/**
* .Ydb.Topic.StreamWriteMessage.WriteRequest write_request = 2;
*/
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequestOrBuilder getWriteRequestOrBuilder();
/**
* .Ydb.Topic.UpdateTokenRequest update_token_request = 3;
* @return Whether the updateTokenRequest field is set.
*/
boolean hasUpdateTokenRequest();
/**
* .Ydb.Topic.UpdateTokenRequest update_token_request = 3;
* @return The updateTokenRequest.
*/
tech.ydb.proto.topic.YdbTopic.UpdateTokenRequest getUpdateTokenRequest();
/**
* .Ydb.Topic.UpdateTokenRequest update_token_request = 3;
*/
tech.ydb.proto.topic.YdbTopic.UpdateTokenRequestOrBuilder getUpdateTokenRequestOrBuilder();
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.FromClient.ClientMessageCase getClientMessageCase();
}
/**
*
* Client-server message for write session. Contains one of:
* InitRequest - handshake request.
* WriteRequest - portion of data to be written.
* UpdateTokenRequest - user credentials if update is needed.
*
*
* Protobuf type {@code Ydb.Topic.StreamWriteMessage.FromClient}
*/
public static final class FromClient extends
com.google.protobuf.GeneratedMessageV3 implements
// @@protoc_insertion_point(message_implements:Ydb.Topic.StreamWriteMessage.FromClient)
FromClientOrBuilder {
private static final long serialVersionUID = 0L;
// Use FromClient.newBuilder() to construct.
private FromClient(com.google.protobuf.GeneratedMessageV3.Builder> builder) {
super(builder);
}
private FromClient() {
}
@java.lang.Override
@SuppressWarnings({"unused"})
protected java.lang.Object newInstance(
UnusedPrivateParameter unused) {
return new FromClient();
}
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_StreamWriteMessage_FromClient_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_StreamWriteMessage_FromClient_fieldAccessorTable
.ensureFieldAccessorsInitialized(
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.FromClient.class, tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.FromClient.Builder.class);
}
private int clientMessageCase_ = 0;
@SuppressWarnings("serial")
private java.lang.Object clientMessage_;
public enum ClientMessageCase
implements com.google.protobuf.Internal.EnumLite,
com.google.protobuf.AbstractMessage.InternalOneOfEnum {
INIT_REQUEST(1),
WRITE_REQUEST(2),
UPDATE_TOKEN_REQUEST(3),
CLIENTMESSAGE_NOT_SET(0);
private final int value;
private ClientMessageCase(int value) {
this.value = value;
}
/**
* @param value The number of the enum to look for.
* @return The enum associated with the given number.
* @deprecated Use {@link #forNumber(int)} instead.
*/
@java.lang.Deprecated
public static ClientMessageCase valueOf(int value) {
return forNumber(value);
}
public static ClientMessageCase forNumber(int value) {
switch (value) {
case 1: return INIT_REQUEST;
case 2: return WRITE_REQUEST;
case 3: return UPDATE_TOKEN_REQUEST;
case 0: return CLIENTMESSAGE_NOT_SET;
default: return null;
}
}
public int getNumber() {
return this.value;
}
};
public ClientMessageCase
getClientMessageCase() {
return ClientMessageCase.forNumber(
clientMessageCase_);
}
public static final int INIT_REQUEST_FIELD_NUMBER = 1;
/**
* .Ydb.Topic.StreamWriteMessage.InitRequest init_request = 1;
* @return Whether the initRequest field is set.
*/
@java.lang.Override
public boolean hasInitRequest() {
return clientMessageCase_ == 1;
}
/**
* .Ydb.Topic.StreamWriteMessage.InitRequest init_request = 1;
* @return The initRequest.
*/
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitRequest getInitRequest() {
if (clientMessageCase_ == 1) {
return (tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitRequest) clientMessage_;
}
return tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitRequest.getDefaultInstance();
}
/**
* .Ydb.Topic.StreamWriteMessage.InitRequest init_request = 1;
*/
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitRequestOrBuilder getInitRequestOrBuilder() {
if (clientMessageCase_ == 1) {
return (tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitRequest) clientMessage_;
}
return tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitRequest.getDefaultInstance();
}
public static final int WRITE_REQUEST_FIELD_NUMBER = 2;
/**
* .Ydb.Topic.StreamWriteMessage.WriteRequest write_request = 2;
* @return Whether the writeRequest field is set.
*/
@java.lang.Override
public boolean hasWriteRequest() {
return clientMessageCase_ == 2;
}
/**
* .Ydb.Topic.StreamWriteMessage.WriteRequest write_request = 2;
* @return The writeRequest.
*/
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest getWriteRequest() {
if (clientMessageCase_ == 2) {
return (tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest) clientMessage_;
}
return tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest.getDefaultInstance();
}
/**
* .Ydb.Topic.StreamWriteMessage.WriteRequest write_request = 2;
*/
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequestOrBuilder getWriteRequestOrBuilder() {
if (clientMessageCase_ == 2) {
return (tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest) clientMessage_;
}
return tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest.getDefaultInstance();
}
public static final int UPDATE_TOKEN_REQUEST_FIELD_NUMBER = 3;
/**
* .Ydb.Topic.UpdateTokenRequest update_token_request = 3;
* @return Whether the updateTokenRequest field is set.
*/
@java.lang.Override
public boolean hasUpdateTokenRequest() {
return clientMessageCase_ == 3;
}
/**
* .Ydb.Topic.UpdateTokenRequest update_token_request = 3;
* @return The updateTokenRequest.
*/
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.UpdateTokenRequest getUpdateTokenRequest() {
if (clientMessageCase_ == 3) {
return (tech.ydb.proto.topic.YdbTopic.UpdateTokenRequest) clientMessage_;
}
return tech.ydb.proto.topic.YdbTopic.UpdateTokenRequest.getDefaultInstance();
}
/**
* .Ydb.Topic.UpdateTokenRequest update_token_request = 3;
*/
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.UpdateTokenRequestOrBuilder getUpdateTokenRequestOrBuilder() {
if (clientMessageCase_ == 3) {
return (tech.ydb.proto.topic.YdbTopic.UpdateTokenRequest) clientMessage_;
}
return tech.ydb.proto.topic.YdbTopic.UpdateTokenRequest.getDefaultInstance();
}
private byte memoizedIsInitialized = -1;
@java.lang.Override
public final boolean isInitialized() {
byte isInitialized = memoizedIsInitialized;
if (isInitialized == 1) return true;
if (isInitialized == 0) return false;
memoizedIsInitialized = 1;
return true;
}
@java.lang.Override
public void writeTo(com.google.protobuf.CodedOutputStream output)
throws java.io.IOException {
if (clientMessageCase_ == 1) {
output.writeMessage(1, (tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitRequest) clientMessage_);
}
if (clientMessageCase_ == 2) {
output.writeMessage(2, (tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest) clientMessage_);
}
if (clientMessageCase_ == 3) {
output.writeMessage(3, (tech.ydb.proto.topic.YdbTopic.UpdateTokenRequest) clientMessage_);
}
getUnknownFields().writeTo(output);
}
@java.lang.Override
public int getSerializedSize() {
int size = memoizedSize;
if (size != -1) return size;
size = 0;
if (clientMessageCase_ == 1) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(1, (tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitRequest) clientMessage_);
}
if (clientMessageCase_ == 2) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(2, (tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest) clientMessage_);
}
if (clientMessageCase_ == 3) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(3, (tech.ydb.proto.topic.YdbTopic.UpdateTokenRequest) clientMessage_);
}
size += getUnknownFields().getSerializedSize();
memoizedSize = size;
return size;
}
@java.lang.Override
public boolean equals(final java.lang.Object obj) {
if (obj == this) {
return true;
}
if (!(obj instanceof tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.FromClient)) {
return super.equals(obj);
}
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.FromClient other = (tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.FromClient) obj;
if (!getClientMessageCase().equals(other.getClientMessageCase())) return false;
switch (clientMessageCase_) {
case 1:
if (!getInitRequest()
.equals(other.getInitRequest())) return false;
break;
case 2:
if (!getWriteRequest()
.equals(other.getWriteRequest())) return false;
break;
case 3:
if (!getUpdateTokenRequest()
.equals(other.getUpdateTokenRequest())) return false;
break;
case 0:
default:
}
if (!getUnknownFields().equals(other.getUnknownFields())) return false;
return true;
}
@java.lang.Override
public int hashCode() {
if (memoizedHashCode != 0) {
return memoizedHashCode;
}
int hash = 41;
hash = (19 * hash) + getDescriptor().hashCode();
switch (clientMessageCase_) {
case 1:
hash = (37 * hash) + INIT_REQUEST_FIELD_NUMBER;
hash = (53 * hash) + getInitRequest().hashCode();
break;
case 2:
hash = (37 * hash) + WRITE_REQUEST_FIELD_NUMBER;
hash = (53 * hash) + getWriteRequest().hashCode();
break;
case 3:
hash = (37 * hash) + UPDATE_TOKEN_REQUEST_FIELD_NUMBER;
hash = (53 * hash) + getUpdateTokenRequest().hashCode();
break;
case 0:
default:
}
hash = (29 * hash) + getUnknownFields().hashCode();
memoizedHashCode = hash;
return hash;
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.FromClient parseFrom(
java.nio.ByteBuffer data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.FromClient parseFrom(
java.nio.ByteBuffer data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.FromClient parseFrom(
com.google.protobuf.ByteString data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.FromClient parseFrom(
com.google.protobuf.ByteString data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.FromClient parseFrom(byte[] data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.FromClient parseFrom(
byte[] data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.FromClient parseFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.FromClient parseFrom(
java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.FromClient parseDelimitedFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input);
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.FromClient parseDelimitedFrom(
java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.FromClient parseFrom(
com.google.protobuf.CodedInputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.FromClient parseFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry);
}
@java.lang.Override
public Builder newBuilderForType() { return newBuilder(); }
public static Builder newBuilder() {
return DEFAULT_INSTANCE.toBuilder();
}
public static Builder newBuilder(tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.FromClient prototype) {
return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
}
@java.lang.Override
public Builder toBuilder() {
return this == DEFAULT_INSTANCE
? new Builder() : new Builder().mergeFrom(this);
}
@java.lang.Override
protected Builder newBuilderForType(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
Builder builder = new Builder(parent);
return builder;
}
/**
*
* Client-server message for write session. Contains one of:
* InitRequest - handshake request.
* WriteRequest - portion of data to be written.
* UpdateTokenRequest - user credentials if update is needed.
*
*
* Protobuf type {@code Ydb.Topic.StreamWriteMessage.FromClient}
*/
public static final class Builder extends
com.google.protobuf.GeneratedMessageV3.Builder implements
// @@protoc_insertion_point(builder_implements:Ydb.Topic.StreamWriteMessage.FromClient)
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.FromClientOrBuilder {
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_StreamWriteMessage_FromClient_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_StreamWriteMessage_FromClient_fieldAccessorTable
.ensureFieldAccessorsInitialized(
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.FromClient.class, tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.FromClient.Builder.class);
}
// Construct using tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.FromClient.newBuilder()
private Builder() {
}
private Builder(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
super(parent);
}
@java.lang.Override
public Builder clear() {
super.clear();
bitField0_ = 0;
if (initRequestBuilder_ != null) {
initRequestBuilder_.clear();
}
if (writeRequestBuilder_ != null) {
writeRequestBuilder_.clear();
}
if (updateTokenRequestBuilder_ != null) {
updateTokenRequestBuilder_.clear();
}
clientMessageCase_ = 0;
clientMessage_ = null;
return this;
}
@java.lang.Override
public com.google.protobuf.Descriptors.Descriptor
getDescriptorForType() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_StreamWriteMessage_FromClient_descriptor;
}
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.FromClient getDefaultInstanceForType() {
return tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.FromClient.getDefaultInstance();
}
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.FromClient build() {
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.FromClient result = buildPartial();
if (!result.isInitialized()) {
throw newUninitializedMessageException(result);
}
return result;
}
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.FromClient buildPartial() {
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.FromClient result = new tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.FromClient(this);
if (bitField0_ != 0) { buildPartial0(result); }
buildPartialOneofs(result);
onBuilt();
return result;
}
private void buildPartial0(tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.FromClient result) {
int from_bitField0_ = bitField0_;
}
private void buildPartialOneofs(tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.FromClient result) {
result.clientMessageCase_ = clientMessageCase_;
result.clientMessage_ = this.clientMessage_;
if (clientMessageCase_ == 1 &&
initRequestBuilder_ != null) {
result.clientMessage_ = initRequestBuilder_.build();
}
if (clientMessageCase_ == 2 &&
writeRequestBuilder_ != null) {
result.clientMessage_ = writeRequestBuilder_.build();
}
if (clientMessageCase_ == 3 &&
updateTokenRequestBuilder_ != null) {
result.clientMessage_ = updateTokenRequestBuilder_.build();
}
}
@java.lang.Override
public Builder clone() {
return super.clone();
}
@java.lang.Override
public Builder setField(
com.google.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) {
return super.setField(field, value);
}
@java.lang.Override
public Builder clearField(
com.google.protobuf.Descriptors.FieldDescriptor field) {
return super.clearField(field);
}
@java.lang.Override
public Builder clearOneof(
com.google.protobuf.Descriptors.OneofDescriptor oneof) {
return super.clearOneof(oneof);
}
@java.lang.Override
public Builder setRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
int index, java.lang.Object value) {
return super.setRepeatedField(field, index, value);
}
@java.lang.Override
public Builder addRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) {
return super.addRepeatedField(field, value);
}
@java.lang.Override
public Builder mergeFrom(com.google.protobuf.Message other) {
if (other instanceof tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.FromClient) {
return mergeFrom((tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.FromClient)other);
} else {
super.mergeFrom(other);
return this;
}
}
public Builder mergeFrom(tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.FromClient other) {
if (other == tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.FromClient.getDefaultInstance()) return this;
switch (other.getClientMessageCase()) {
case INIT_REQUEST: {
mergeInitRequest(other.getInitRequest());
break;
}
case WRITE_REQUEST: {
mergeWriteRequest(other.getWriteRequest());
break;
}
case UPDATE_TOKEN_REQUEST: {
mergeUpdateTokenRequest(other.getUpdateTokenRequest());
break;
}
case CLIENTMESSAGE_NOT_SET: {
break;
}
}
this.mergeUnknownFields(other.getUnknownFields());
onChanged();
return this;
}
@java.lang.Override
public final boolean isInitialized() {
return true;
}
@java.lang.Override
public Builder mergeFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
if (extensionRegistry == null) {
throw new java.lang.NullPointerException();
}
try {
boolean done = false;
while (!done) {
int tag = input.readTag();
switch (tag) {
case 0:
done = true;
break;
case 10: {
input.readMessage(
getInitRequestFieldBuilder().getBuilder(),
extensionRegistry);
clientMessageCase_ = 1;
break;
} // case 10
case 18: {
input.readMessage(
getWriteRequestFieldBuilder().getBuilder(),
extensionRegistry);
clientMessageCase_ = 2;
break;
} // case 18
case 26: {
input.readMessage(
getUpdateTokenRequestFieldBuilder().getBuilder(),
extensionRegistry);
clientMessageCase_ = 3;
break;
} // case 26
default: {
if (!super.parseUnknownField(input, extensionRegistry, tag)) {
done = true; // was an endgroup tag
}
break;
} // default:
} // switch (tag)
} // while (!done)
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.unwrapIOException();
} finally {
onChanged();
} // finally
return this;
}
private int clientMessageCase_ = 0;
private java.lang.Object clientMessage_;
public ClientMessageCase
getClientMessageCase() {
return ClientMessageCase.forNumber(
clientMessageCase_);
}
public Builder clearClientMessage() {
clientMessageCase_ = 0;
clientMessage_ = null;
onChanged();
return this;
}
private int bitField0_;
private com.google.protobuf.SingleFieldBuilderV3<
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitRequest, tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitRequest.Builder, tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitRequestOrBuilder> initRequestBuilder_;
/**
* .Ydb.Topic.StreamWriteMessage.InitRequest init_request = 1;
* @return Whether the initRequest field is set.
*/
@java.lang.Override
public boolean hasInitRequest() {
return clientMessageCase_ == 1;
}
/**
* .Ydb.Topic.StreamWriteMessage.InitRequest init_request = 1;
* @return The initRequest.
*/
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitRequest getInitRequest() {
if (initRequestBuilder_ == null) {
if (clientMessageCase_ == 1) {
return (tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitRequest) clientMessage_;
}
return tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitRequest.getDefaultInstance();
} else {
if (clientMessageCase_ == 1) {
return initRequestBuilder_.getMessage();
}
return tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitRequest.getDefaultInstance();
}
}
/**
* .Ydb.Topic.StreamWriteMessage.InitRequest init_request = 1;
*/
public Builder setInitRequest(tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitRequest value) {
if (initRequestBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
clientMessage_ = value;
onChanged();
} else {
initRequestBuilder_.setMessage(value);
}
clientMessageCase_ = 1;
return this;
}
/**
* .Ydb.Topic.StreamWriteMessage.InitRequest init_request = 1;
*/
public Builder setInitRequest(
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitRequest.Builder builderForValue) {
if (initRequestBuilder_ == null) {
clientMessage_ = builderForValue.build();
onChanged();
} else {
initRequestBuilder_.setMessage(builderForValue.build());
}
clientMessageCase_ = 1;
return this;
}
/**
* .Ydb.Topic.StreamWriteMessage.InitRequest init_request = 1;
*/
public Builder mergeInitRequest(tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitRequest value) {
if (initRequestBuilder_ == null) {
if (clientMessageCase_ == 1 &&
clientMessage_ != tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitRequest.getDefaultInstance()) {
clientMessage_ = tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitRequest.newBuilder((tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitRequest) clientMessage_)
.mergeFrom(value).buildPartial();
} else {
clientMessage_ = value;
}
onChanged();
} else {
if (clientMessageCase_ == 1) {
initRequestBuilder_.mergeFrom(value);
} else {
initRequestBuilder_.setMessage(value);
}
}
clientMessageCase_ = 1;
return this;
}
/**
* .Ydb.Topic.StreamWriteMessage.InitRequest init_request = 1;
*/
public Builder clearInitRequest() {
if (initRequestBuilder_ == null) {
if (clientMessageCase_ == 1) {
clientMessageCase_ = 0;
clientMessage_ = null;
onChanged();
}
} else {
if (clientMessageCase_ == 1) {
clientMessageCase_ = 0;
clientMessage_ = null;
}
initRequestBuilder_.clear();
}
return this;
}
/**
* .Ydb.Topic.StreamWriteMessage.InitRequest init_request = 1;
*/
public tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitRequest.Builder getInitRequestBuilder() {
return getInitRequestFieldBuilder().getBuilder();
}
/**
* .Ydb.Topic.StreamWriteMessage.InitRequest init_request = 1;
*/
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitRequestOrBuilder getInitRequestOrBuilder() {
if ((clientMessageCase_ == 1) && (initRequestBuilder_ != null)) {
return initRequestBuilder_.getMessageOrBuilder();
} else {
if (clientMessageCase_ == 1) {
return (tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitRequest) clientMessage_;
}
return tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitRequest.getDefaultInstance();
}
}
/**
* .Ydb.Topic.StreamWriteMessage.InitRequest init_request = 1;
*/
private com.google.protobuf.SingleFieldBuilderV3<
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitRequest, tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitRequest.Builder, tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitRequestOrBuilder>
getInitRequestFieldBuilder() {
if (initRequestBuilder_ == null) {
if (!(clientMessageCase_ == 1)) {
clientMessage_ = tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitRequest.getDefaultInstance();
}
initRequestBuilder_ = new com.google.protobuf.SingleFieldBuilderV3<
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitRequest, tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitRequest.Builder, tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitRequestOrBuilder>(
(tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitRequest) clientMessage_,
getParentForChildren(),
isClean());
clientMessage_ = null;
}
clientMessageCase_ = 1;
onChanged();
return initRequestBuilder_;
}
private com.google.protobuf.SingleFieldBuilderV3<
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest, tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest.Builder, tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequestOrBuilder> writeRequestBuilder_;
/**
* .Ydb.Topic.StreamWriteMessage.WriteRequest write_request = 2;
* @return Whether the writeRequest field is set.
*/
@java.lang.Override
public boolean hasWriteRequest() {
return clientMessageCase_ == 2;
}
/**
* .Ydb.Topic.StreamWriteMessage.WriteRequest write_request = 2;
* @return The writeRequest.
*/
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest getWriteRequest() {
if (writeRequestBuilder_ == null) {
if (clientMessageCase_ == 2) {
return (tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest) clientMessage_;
}
return tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest.getDefaultInstance();
} else {
if (clientMessageCase_ == 2) {
return writeRequestBuilder_.getMessage();
}
return tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest.getDefaultInstance();
}
}
/**
* .Ydb.Topic.StreamWriteMessage.WriteRequest write_request = 2;
*/
public Builder setWriteRequest(tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest value) {
if (writeRequestBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
clientMessage_ = value;
onChanged();
} else {
writeRequestBuilder_.setMessage(value);
}
clientMessageCase_ = 2;
return this;
}
/**
* .Ydb.Topic.StreamWriteMessage.WriteRequest write_request = 2;
*/
public Builder setWriteRequest(
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest.Builder builderForValue) {
if (writeRequestBuilder_ == null) {
clientMessage_ = builderForValue.build();
onChanged();
} else {
writeRequestBuilder_.setMessage(builderForValue.build());
}
clientMessageCase_ = 2;
return this;
}
/**
* .Ydb.Topic.StreamWriteMessage.WriteRequest write_request = 2;
*/
public Builder mergeWriteRequest(tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest value) {
if (writeRequestBuilder_ == null) {
if (clientMessageCase_ == 2 &&
clientMessage_ != tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest.getDefaultInstance()) {
clientMessage_ = tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest.newBuilder((tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest) clientMessage_)
.mergeFrom(value).buildPartial();
} else {
clientMessage_ = value;
}
onChanged();
} else {
if (clientMessageCase_ == 2) {
writeRequestBuilder_.mergeFrom(value);
} else {
writeRequestBuilder_.setMessage(value);
}
}
clientMessageCase_ = 2;
return this;
}
/**
* .Ydb.Topic.StreamWriteMessage.WriteRequest write_request = 2;
*/
public Builder clearWriteRequest() {
if (writeRequestBuilder_ == null) {
if (clientMessageCase_ == 2) {
clientMessageCase_ = 0;
clientMessage_ = null;
onChanged();
}
} else {
if (clientMessageCase_ == 2) {
clientMessageCase_ = 0;
clientMessage_ = null;
}
writeRequestBuilder_.clear();
}
return this;
}
/**
* .Ydb.Topic.StreamWriteMessage.WriteRequest write_request = 2;
*/
public tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest.Builder getWriteRequestBuilder() {
return getWriteRequestFieldBuilder().getBuilder();
}
/**
* .Ydb.Topic.StreamWriteMessage.WriteRequest write_request = 2;
*/
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequestOrBuilder getWriteRequestOrBuilder() {
if ((clientMessageCase_ == 2) && (writeRequestBuilder_ != null)) {
return writeRequestBuilder_.getMessageOrBuilder();
} else {
if (clientMessageCase_ == 2) {
return (tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest) clientMessage_;
}
return tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest.getDefaultInstance();
}
}
/**
* .Ydb.Topic.StreamWriteMessage.WriteRequest write_request = 2;
*/
private com.google.protobuf.SingleFieldBuilderV3<
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest, tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest.Builder, tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequestOrBuilder>
getWriteRequestFieldBuilder() {
if (writeRequestBuilder_ == null) {
if (!(clientMessageCase_ == 2)) {
clientMessage_ = tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest.getDefaultInstance();
}
writeRequestBuilder_ = new com.google.protobuf.SingleFieldBuilderV3<
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest, tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest.Builder, tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequestOrBuilder>(
(tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest) clientMessage_,
getParentForChildren(),
isClean());
clientMessage_ = null;
}
clientMessageCase_ = 2;
onChanged();
return writeRequestBuilder_;
}
private com.google.protobuf.SingleFieldBuilderV3<
tech.ydb.proto.topic.YdbTopic.UpdateTokenRequest, tech.ydb.proto.topic.YdbTopic.UpdateTokenRequest.Builder, tech.ydb.proto.topic.YdbTopic.UpdateTokenRequestOrBuilder> updateTokenRequestBuilder_;
/**
* .Ydb.Topic.UpdateTokenRequest update_token_request = 3;
* @return Whether the updateTokenRequest field is set.
*/
@java.lang.Override
public boolean hasUpdateTokenRequest() {
return clientMessageCase_ == 3;
}
/**
* .Ydb.Topic.UpdateTokenRequest update_token_request = 3;
* @return The updateTokenRequest.
*/
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.UpdateTokenRequest getUpdateTokenRequest() {
if (updateTokenRequestBuilder_ == null) {
if (clientMessageCase_ == 3) {
return (tech.ydb.proto.topic.YdbTopic.UpdateTokenRequest) clientMessage_;
}
return tech.ydb.proto.topic.YdbTopic.UpdateTokenRequest.getDefaultInstance();
} else {
if (clientMessageCase_ == 3) {
return updateTokenRequestBuilder_.getMessage();
}
return tech.ydb.proto.topic.YdbTopic.UpdateTokenRequest.getDefaultInstance();
}
}
/**
* .Ydb.Topic.UpdateTokenRequest update_token_request = 3;
*/
public Builder setUpdateTokenRequest(tech.ydb.proto.topic.YdbTopic.UpdateTokenRequest value) {
if (updateTokenRequestBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
clientMessage_ = value;
onChanged();
} else {
updateTokenRequestBuilder_.setMessage(value);
}
clientMessageCase_ = 3;
return this;
}
/**
* .Ydb.Topic.UpdateTokenRequest update_token_request = 3;
*/
public Builder setUpdateTokenRequest(
tech.ydb.proto.topic.YdbTopic.UpdateTokenRequest.Builder builderForValue) {
if (updateTokenRequestBuilder_ == null) {
clientMessage_ = builderForValue.build();
onChanged();
} else {
updateTokenRequestBuilder_.setMessage(builderForValue.build());
}
clientMessageCase_ = 3;
return this;
}
/**
* .Ydb.Topic.UpdateTokenRequest update_token_request = 3;
*/
public Builder mergeUpdateTokenRequest(tech.ydb.proto.topic.YdbTopic.UpdateTokenRequest value) {
if (updateTokenRequestBuilder_ == null) {
if (clientMessageCase_ == 3 &&
clientMessage_ != tech.ydb.proto.topic.YdbTopic.UpdateTokenRequest.getDefaultInstance()) {
clientMessage_ = tech.ydb.proto.topic.YdbTopic.UpdateTokenRequest.newBuilder((tech.ydb.proto.topic.YdbTopic.UpdateTokenRequest) clientMessage_)
.mergeFrom(value).buildPartial();
} else {
clientMessage_ = value;
}
onChanged();
} else {
if (clientMessageCase_ == 3) {
updateTokenRequestBuilder_.mergeFrom(value);
} else {
updateTokenRequestBuilder_.setMessage(value);
}
}
clientMessageCase_ = 3;
return this;
}
/**
* .Ydb.Topic.UpdateTokenRequest update_token_request = 3;
*/
public Builder clearUpdateTokenRequest() {
if (updateTokenRequestBuilder_ == null) {
if (clientMessageCase_ == 3) {
clientMessageCase_ = 0;
clientMessage_ = null;
onChanged();
}
} else {
if (clientMessageCase_ == 3) {
clientMessageCase_ = 0;
clientMessage_ = null;
}
updateTokenRequestBuilder_.clear();
}
return this;
}
/**
* .Ydb.Topic.UpdateTokenRequest update_token_request = 3;
*/
public tech.ydb.proto.topic.YdbTopic.UpdateTokenRequest.Builder getUpdateTokenRequestBuilder() {
return getUpdateTokenRequestFieldBuilder().getBuilder();
}
/**
* .Ydb.Topic.UpdateTokenRequest update_token_request = 3;
*/
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.UpdateTokenRequestOrBuilder getUpdateTokenRequestOrBuilder() {
if ((clientMessageCase_ == 3) && (updateTokenRequestBuilder_ != null)) {
return updateTokenRequestBuilder_.getMessageOrBuilder();
} else {
if (clientMessageCase_ == 3) {
return (tech.ydb.proto.topic.YdbTopic.UpdateTokenRequest) clientMessage_;
}
return tech.ydb.proto.topic.YdbTopic.UpdateTokenRequest.getDefaultInstance();
}
}
/**
* .Ydb.Topic.UpdateTokenRequest update_token_request = 3;
*/
private com.google.protobuf.SingleFieldBuilderV3<
tech.ydb.proto.topic.YdbTopic.UpdateTokenRequest, tech.ydb.proto.topic.YdbTopic.UpdateTokenRequest.Builder, tech.ydb.proto.topic.YdbTopic.UpdateTokenRequestOrBuilder>
getUpdateTokenRequestFieldBuilder() {
if (updateTokenRequestBuilder_ == null) {
if (!(clientMessageCase_ == 3)) {
clientMessage_ = tech.ydb.proto.topic.YdbTopic.UpdateTokenRequest.getDefaultInstance();
}
updateTokenRequestBuilder_ = new com.google.protobuf.SingleFieldBuilderV3<
tech.ydb.proto.topic.YdbTopic.UpdateTokenRequest, tech.ydb.proto.topic.YdbTopic.UpdateTokenRequest.Builder, tech.ydb.proto.topic.YdbTopic.UpdateTokenRequestOrBuilder>(
(tech.ydb.proto.topic.YdbTopic.UpdateTokenRequest) clientMessage_,
getParentForChildren(),
isClean());
clientMessage_ = null;
}
clientMessageCase_ = 3;
onChanged();
return updateTokenRequestBuilder_;
}
@java.lang.Override
public final Builder setUnknownFields(
final com.google.protobuf.UnknownFieldSet unknownFields) {
return super.setUnknownFields(unknownFields);
}
@java.lang.Override
public final Builder mergeUnknownFields(
final com.google.protobuf.UnknownFieldSet unknownFields) {
return super.mergeUnknownFields(unknownFields);
}
// @@protoc_insertion_point(builder_scope:Ydb.Topic.StreamWriteMessage.FromClient)
}
// @@protoc_insertion_point(class_scope:Ydb.Topic.StreamWriteMessage.FromClient)
private static final tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.FromClient DEFAULT_INSTANCE;
static {
DEFAULT_INSTANCE = new tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.FromClient();
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.FromClient getDefaultInstance() {
return DEFAULT_INSTANCE;
}
private static final com.google.protobuf.Parser
PARSER = new com.google.protobuf.AbstractParser() {
@java.lang.Override
public FromClient parsePartialFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
Builder builder = newBuilder();
try {
builder.mergeFrom(input, extensionRegistry);
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.setUnfinishedMessage(builder.buildPartial());
} catch (com.google.protobuf.UninitializedMessageException e) {
throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial());
} catch (java.io.IOException e) {
throw new com.google.protobuf.InvalidProtocolBufferException(e)
.setUnfinishedMessage(builder.buildPartial());
}
return builder.buildPartial();
}
};
public static com.google.protobuf.Parser parser() {
return PARSER;
}
@java.lang.Override
public com.google.protobuf.Parser getParserForType() {
return PARSER;
}
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.FromClient getDefaultInstanceForType() {
return DEFAULT_INSTANCE;
}
}
public interface FromServerOrBuilder extends
// @@protoc_insertion_point(interface_extends:Ydb.Topic.StreamWriteMessage.FromServer)
com.google.protobuf.MessageOrBuilder {
/**
*
* Server status of response.
*
*
* .Ydb.StatusIds.StatusCode status = 1;
* @return The enum numeric value on the wire for status.
*/
int getStatusValue();
/**
*
* Server status of response.
*
*
* .Ydb.StatusIds.StatusCode status = 1;
* @return The status.
*/
tech.ydb.proto.StatusCodesProtos.StatusIds.StatusCode getStatus();
/**
*
* Issues if any.
*
*
* repeated .Ydb.Issue.IssueMessage issues = 2;
*/
java.util.List
getIssuesList();
/**
*
* Issues if any.
*
*
* repeated .Ydb.Issue.IssueMessage issues = 2;
*/
tech.ydb.proto.YdbIssueMessage.IssueMessage getIssues(int index);
/**
*
* Issues if any.
*
*
* repeated .Ydb.Issue.IssueMessage issues = 2;
*/
int getIssuesCount();
/**
*
* Issues if any.
*
*
* repeated .Ydb.Issue.IssueMessage issues = 2;
*/
java.util.List extends tech.ydb.proto.YdbIssueMessage.IssueMessageOrBuilder>
getIssuesOrBuilderList();
/**
*
* Issues if any.
*
*
* repeated .Ydb.Issue.IssueMessage issues = 2;
*/
tech.ydb.proto.YdbIssueMessage.IssueMessageOrBuilder getIssuesOrBuilder(
int index);
/**
* .Ydb.Topic.StreamWriteMessage.InitResponse init_response = 3;
* @return Whether the initResponse field is set.
*/
boolean hasInitResponse();
/**
* .Ydb.Topic.StreamWriteMessage.InitResponse init_response = 3;
* @return The initResponse.
*/
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitResponse getInitResponse();
/**
* .Ydb.Topic.StreamWriteMessage.InitResponse init_response = 3;
*/
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitResponseOrBuilder getInitResponseOrBuilder();
/**
* .Ydb.Topic.StreamWriteMessage.WriteResponse write_response = 4;
* @return Whether the writeResponse field is set.
*/
boolean hasWriteResponse();
/**
* .Ydb.Topic.StreamWriteMessage.WriteResponse write_response = 4;
* @return The writeResponse.
*/
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse getWriteResponse();
/**
* .Ydb.Topic.StreamWriteMessage.WriteResponse write_response = 4;
*/
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponseOrBuilder getWriteResponseOrBuilder();
/**
* .Ydb.Topic.UpdateTokenResponse update_token_response = 5;
* @return Whether the updateTokenResponse field is set.
*/
boolean hasUpdateTokenResponse();
/**
* .Ydb.Topic.UpdateTokenResponse update_token_response = 5;
* @return The updateTokenResponse.
*/
tech.ydb.proto.topic.YdbTopic.UpdateTokenResponse getUpdateTokenResponse();
/**
* .Ydb.Topic.UpdateTokenResponse update_token_response = 5;
*/
tech.ydb.proto.topic.YdbTopic.UpdateTokenResponseOrBuilder getUpdateTokenResponseOrBuilder();
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.FromServer.ServerMessageCase getServerMessageCase();
}
/**
*
* Server-client message for write session. Contains either non-success status, or one of:
* InitResponse - correct handshake response.
* WriteResponse - acknowledgment of storing client messages.
* UpdateTokenResponse - acknowledgment of reauthentication and reauthorization.
*
*
* Protobuf type {@code Ydb.Topic.StreamWriteMessage.FromServer}
*/
public static final class FromServer extends
com.google.protobuf.GeneratedMessageV3 implements
// @@protoc_insertion_point(message_implements:Ydb.Topic.StreamWriteMessage.FromServer)
FromServerOrBuilder {
private static final long serialVersionUID = 0L;
// Use FromServer.newBuilder() to construct.
private FromServer(com.google.protobuf.GeneratedMessageV3.Builder> builder) {
super(builder);
}
private FromServer() {
status_ = 0;
issues_ = java.util.Collections.emptyList();
}
@java.lang.Override
@SuppressWarnings({"unused"})
protected java.lang.Object newInstance(
UnusedPrivateParameter unused) {
return new FromServer();
}
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_StreamWriteMessage_FromServer_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_StreamWriteMessage_FromServer_fieldAccessorTable
.ensureFieldAccessorsInitialized(
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.FromServer.class, tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.FromServer.Builder.class);
}
private int serverMessageCase_ = 0;
@SuppressWarnings("serial")
private java.lang.Object serverMessage_;
public enum ServerMessageCase
implements com.google.protobuf.Internal.EnumLite,
com.google.protobuf.AbstractMessage.InternalOneOfEnum {
INIT_RESPONSE(3),
WRITE_RESPONSE(4),
UPDATE_TOKEN_RESPONSE(5),
SERVERMESSAGE_NOT_SET(0);
private final int value;
private ServerMessageCase(int value) {
this.value = value;
}
/**
* @param value The number of the enum to look for.
* @return The enum associated with the given number.
* @deprecated Use {@link #forNumber(int)} instead.
*/
@java.lang.Deprecated
public static ServerMessageCase valueOf(int value) {
return forNumber(value);
}
public static ServerMessageCase forNumber(int value) {
switch (value) {
case 3: return INIT_RESPONSE;
case 4: return WRITE_RESPONSE;
case 5: return UPDATE_TOKEN_RESPONSE;
case 0: return SERVERMESSAGE_NOT_SET;
default: return null;
}
}
public int getNumber() {
return this.value;
}
};
public ServerMessageCase
getServerMessageCase() {
return ServerMessageCase.forNumber(
serverMessageCase_);
}
public static final int STATUS_FIELD_NUMBER = 1;
private int status_ = 0;
/**
*
* Server status of response.
*
*
* .Ydb.StatusIds.StatusCode status = 1;
* @return The enum numeric value on the wire for status.
*/
@java.lang.Override public int getStatusValue() {
return status_;
}
/**
*
* Server status of response.
*
*
* .Ydb.StatusIds.StatusCode status = 1;
* @return The status.
*/
@java.lang.Override public tech.ydb.proto.StatusCodesProtos.StatusIds.StatusCode getStatus() {
tech.ydb.proto.StatusCodesProtos.StatusIds.StatusCode result = tech.ydb.proto.StatusCodesProtos.StatusIds.StatusCode.forNumber(status_);
return result == null ? tech.ydb.proto.StatusCodesProtos.StatusIds.StatusCode.UNRECOGNIZED : result;
}
public static final int ISSUES_FIELD_NUMBER = 2;
@SuppressWarnings("serial")
private java.util.List issues_;
/**
*
* Issues if any.
*
*
* repeated .Ydb.Issue.IssueMessage issues = 2;
*/
@java.lang.Override
public java.util.List getIssuesList() {
return issues_;
}
/**
*
* Issues if any.
*
*
* repeated .Ydb.Issue.IssueMessage issues = 2;
*/
@java.lang.Override
public java.util.List extends tech.ydb.proto.YdbIssueMessage.IssueMessageOrBuilder>
getIssuesOrBuilderList() {
return issues_;
}
/**
*
* Issues if any.
*
*
* repeated .Ydb.Issue.IssueMessage issues = 2;
*/
@java.lang.Override
public int getIssuesCount() {
return issues_.size();
}
/**
*
* Issues if any.
*
*
* repeated .Ydb.Issue.IssueMessage issues = 2;
*/
@java.lang.Override
public tech.ydb.proto.YdbIssueMessage.IssueMessage getIssues(int index) {
return issues_.get(index);
}
/**
*
* Issues if any.
*
*
* repeated .Ydb.Issue.IssueMessage issues = 2;
*/
@java.lang.Override
public tech.ydb.proto.YdbIssueMessage.IssueMessageOrBuilder getIssuesOrBuilder(
int index) {
return issues_.get(index);
}
public static final int INIT_RESPONSE_FIELD_NUMBER = 3;
/**
* .Ydb.Topic.StreamWriteMessage.InitResponse init_response = 3;
* @return Whether the initResponse field is set.
*/
@java.lang.Override
public boolean hasInitResponse() {
return serverMessageCase_ == 3;
}
/**
* .Ydb.Topic.StreamWriteMessage.InitResponse init_response = 3;
* @return The initResponse.
*/
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitResponse getInitResponse() {
if (serverMessageCase_ == 3) {
return (tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitResponse) serverMessage_;
}
return tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitResponse.getDefaultInstance();
}
/**
* .Ydb.Topic.StreamWriteMessage.InitResponse init_response = 3;
*/
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitResponseOrBuilder getInitResponseOrBuilder() {
if (serverMessageCase_ == 3) {
return (tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitResponse) serverMessage_;
}
return tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitResponse.getDefaultInstance();
}
public static final int WRITE_RESPONSE_FIELD_NUMBER = 4;
/**
* .Ydb.Topic.StreamWriteMessage.WriteResponse write_response = 4;
* @return Whether the writeResponse field is set.
*/
@java.lang.Override
public boolean hasWriteResponse() {
return serverMessageCase_ == 4;
}
/**
* .Ydb.Topic.StreamWriteMessage.WriteResponse write_response = 4;
* @return The writeResponse.
*/
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse getWriteResponse() {
if (serverMessageCase_ == 4) {
return (tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse) serverMessage_;
}
return tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.getDefaultInstance();
}
/**
* .Ydb.Topic.StreamWriteMessage.WriteResponse write_response = 4;
*/
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponseOrBuilder getWriteResponseOrBuilder() {
if (serverMessageCase_ == 4) {
return (tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse) serverMessage_;
}
return tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.getDefaultInstance();
}
public static final int UPDATE_TOKEN_RESPONSE_FIELD_NUMBER = 5;
/**
* .Ydb.Topic.UpdateTokenResponse update_token_response = 5;
* @return Whether the updateTokenResponse field is set.
*/
@java.lang.Override
public boolean hasUpdateTokenResponse() {
return serverMessageCase_ == 5;
}
/**
* .Ydb.Topic.UpdateTokenResponse update_token_response = 5;
* @return The updateTokenResponse.
*/
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.UpdateTokenResponse getUpdateTokenResponse() {
if (serverMessageCase_ == 5) {
return (tech.ydb.proto.topic.YdbTopic.UpdateTokenResponse) serverMessage_;
}
return tech.ydb.proto.topic.YdbTopic.UpdateTokenResponse.getDefaultInstance();
}
/**
* .Ydb.Topic.UpdateTokenResponse update_token_response = 5;
*/
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.UpdateTokenResponseOrBuilder getUpdateTokenResponseOrBuilder() {
if (serverMessageCase_ == 5) {
return (tech.ydb.proto.topic.YdbTopic.UpdateTokenResponse) serverMessage_;
}
return tech.ydb.proto.topic.YdbTopic.UpdateTokenResponse.getDefaultInstance();
}
private byte memoizedIsInitialized = -1;
@java.lang.Override
public final boolean isInitialized() {
byte isInitialized = memoizedIsInitialized;
if (isInitialized == 1) return true;
if (isInitialized == 0) return false;
memoizedIsInitialized = 1;
return true;
}
@java.lang.Override
public void writeTo(com.google.protobuf.CodedOutputStream output)
throws java.io.IOException {
if (status_ != tech.ydb.proto.StatusCodesProtos.StatusIds.StatusCode.STATUS_CODE_UNSPECIFIED.getNumber()) {
output.writeEnum(1, status_);
}
for (int i = 0; i < issues_.size(); i++) {
output.writeMessage(2, issues_.get(i));
}
if (serverMessageCase_ == 3) {
output.writeMessage(3, (tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitResponse) serverMessage_);
}
if (serverMessageCase_ == 4) {
output.writeMessage(4, (tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse) serverMessage_);
}
if (serverMessageCase_ == 5) {
output.writeMessage(5, (tech.ydb.proto.topic.YdbTopic.UpdateTokenResponse) serverMessage_);
}
getUnknownFields().writeTo(output);
}
@java.lang.Override
public int getSerializedSize() {
int size = memoizedSize;
if (size != -1) return size;
size = 0;
if (status_ != tech.ydb.proto.StatusCodesProtos.StatusIds.StatusCode.STATUS_CODE_UNSPECIFIED.getNumber()) {
size += com.google.protobuf.CodedOutputStream
.computeEnumSize(1, status_);
}
for (int i = 0; i < issues_.size(); i++) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(2, issues_.get(i));
}
if (serverMessageCase_ == 3) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(3, (tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitResponse) serverMessage_);
}
if (serverMessageCase_ == 4) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(4, (tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse) serverMessage_);
}
if (serverMessageCase_ == 5) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(5, (tech.ydb.proto.topic.YdbTopic.UpdateTokenResponse) serverMessage_);
}
size += getUnknownFields().getSerializedSize();
memoizedSize = size;
return size;
}
@java.lang.Override
public boolean equals(final java.lang.Object obj) {
if (obj == this) {
return true;
}
if (!(obj instanceof tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.FromServer)) {
return super.equals(obj);
}
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.FromServer other = (tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.FromServer) obj;
if (status_ != other.status_) return false;
if (!getIssuesList()
.equals(other.getIssuesList())) return false;
if (!getServerMessageCase().equals(other.getServerMessageCase())) return false;
switch (serverMessageCase_) {
case 3:
if (!getInitResponse()
.equals(other.getInitResponse())) return false;
break;
case 4:
if (!getWriteResponse()
.equals(other.getWriteResponse())) return false;
break;
case 5:
if (!getUpdateTokenResponse()
.equals(other.getUpdateTokenResponse())) return false;
break;
case 0:
default:
}
if (!getUnknownFields().equals(other.getUnknownFields())) return false;
return true;
}
@java.lang.Override
public int hashCode() {
if (memoizedHashCode != 0) {
return memoizedHashCode;
}
int hash = 41;
hash = (19 * hash) + getDescriptor().hashCode();
hash = (37 * hash) + STATUS_FIELD_NUMBER;
hash = (53 * hash) + status_;
if (getIssuesCount() > 0) {
hash = (37 * hash) + ISSUES_FIELD_NUMBER;
hash = (53 * hash) + getIssuesList().hashCode();
}
switch (serverMessageCase_) {
case 3:
hash = (37 * hash) + INIT_RESPONSE_FIELD_NUMBER;
hash = (53 * hash) + getInitResponse().hashCode();
break;
case 4:
hash = (37 * hash) + WRITE_RESPONSE_FIELD_NUMBER;
hash = (53 * hash) + getWriteResponse().hashCode();
break;
case 5:
hash = (37 * hash) + UPDATE_TOKEN_RESPONSE_FIELD_NUMBER;
hash = (53 * hash) + getUpdateTokenResponse().hashCode();
break;
case 0:
default:
}
hash = (29 * hash) + getUnknownFields().hashCode();
memoizedHashCode = hash;
return hash;
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.FromServer parseFrom(
java.nio.ByteBuffer data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.FromServer parseFrom(
java.nio.ByteBuffer data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.FromServer parseFrom(
com.google.protobuf.ByteString data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.FromServer parseFrom(
com.google.protobuf.ByteString data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.FromServer parseFrom(byte[] data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.FromServer parseFrom(
byte[] data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.FromServer parseFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.FromServer parseFrom(
java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.FromServer parseDelimitedFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input);
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.FromServer parseDelimitedFrom(
java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.FromServer parseFrom(
com.google.protobuf.CodedInputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.FromServer parseFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry);
}
@java.lang.Override
public Builder newBuilderForType() { return newBuilder(); }
public static Builder newBuilder() {
return DEFAULT_INSTANCE.toBuilder();
}
public static Builder newBuilder(tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.FromServer prototype) {
return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
}
@java.lang.Override
public Builder toBuilder() {
return this == DEFAULT_INSTANCE
? new Builder() : new Builder().mergeFrom(this);
}
@java.lang.Override
protected Builder newBuilderForType(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
Builder builder = new Builder(parent);
return builder;
}
/**
*
* Server-client message for write session. Contains either non-success status, or one of:
* InitResponse - correct handshake response.
* WriteResponse - acknowledgment of storing client messages.
* UpdateTokenResponse - acknowledgment of reauthentication and reauthorization.
*
*
* Protobuf type {@code Ydb.Topic.StreamWriteMessage.FromServer}
*/
public static final class Builder extends
com.google.protobuf.GeneratedMessageV3.Builder implements
// @@protoc_insertion_point(builder_implements:Ydb.Topic.StreamWriteMessage.FromServer)
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.FromServerOrBuilder {
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_StreamWriteMessage_FromServer_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_StreamWriteMessage_FromServer_fieldAccessorTable
.ensureFieldAccessorsInitialized(
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.FromServer.class, tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.FromServer.Builder.class);
}
// Construct using tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.FromServer.newBuilder()
private Builder() {
}
private Builder(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
super(parent);
}
@java.lang.Override
public Builder clear() {
super.clear();
bitField0_ = 0;
status_ = 0;
if (issuesBuilder_ == null) {
issues_ = java.util.Collections.emptyList();
} else {
issues_ = null;
issuesBuilder_.clear();
}
bitField0_ = (bitField0_ & ~0x00000002);
if (initResponseBuilder_ != null) {
initResponseBuilder_.clear();
}
if (writeResponseBuilder_ != null) {
writeResponseBuilder_.clear();
}
if (updateTokenResponseBuilder_ != null) {
updateTokenResponseBuilder_.clear();
}
serverMessageCase_ = 0;
serverMessage_ = null;
return this;
}
@java.lang.Override
public com.google.protobuf.Descriptors.Descriptor
getDescriptorForType() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_StreamWriteMessage_FromServer_descriptor;
}
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.FromServer getDefaultInstanceForType() {
return tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.FromServer.getDefaultInstance();
}
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.FromServer build() {
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.FromServer result = buildPartial();
if (!result.isInitialized()) {
throw newUninitializedMessageException(result);
}
return result;
}
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.FromServer buildPartial() {
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.FromServer result = new tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.FromServer(this);
buildPartialRepeatedFields(result);
if (bitField0_ != 0) { buildPartial0(result); }
buildPartialOneofs(result);
onBuilt();
return result;
}
private void buildPartialRepeatedFields(tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.FromServer result) {
if (issuesBuilder_ == null) {
if (((bitField0_ & 0x00000002) != 0)) {
issues_ = java.util.Collections.unmodifiableList(issues_);
bitField0_ = (bitField0_ & ~0x00000002);
}
result.issues_ = issues_;
} else {
result.issues_ = issuesBuilder_.build();
}
}
private void buildPartial0(tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.FromServer result) {
int from_bitField0_ = bitField0_;
if (((from_bitField0_ & 0x00000001) != 0)) {
result.status_ = status_;
}
}
private void buildPartialOneofs(tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.FromServer result) {
result.serverMessageCase_ = serverMessageCase_;
result.serverMessage_ = this.serverMessage_;
if (serverMessageCase_ == 3 &&
initResponseBuilder_ != null) {
result.serverMessage_ = initResponseBuilder_.build();
}
if (serverMessageCase_ == 4 &&
writeResponseBuilder_ != null) {
result.serverMessage_ = writeResponseBuilder_.build();
}
if (serverMessageCase_ == 5 &&
updateTokenResponseBuilder_ != null) {
result.serverMessage_ = updateTokenResponseBuilder_.build();
}
}
@java.lang.Override
public Builder clone() {
return super.clone();
}
@java.lang.Override
public Builder setField(
com.google.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) {
return super.setField(field, value);
}
@java.lang.Override
public Builder clearField(
com.google.protobuf.Descriptors.FieldDescriptor field) {
return super.clearField(field);
}
@java.lang.Override
public Builder clearOneof(
com.google.protobuf.Descriptors.OneofDescriptor oneof) {
return super.clearOneof(oneof);
}
@java.lang.Override
public Builder setRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
int index, java.lang.Object value) {
return super.setRepeatedField(field, index, value);
}
@java.lang.Override
public Builder addRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) {
return super.addRepeatedField(field, value);
}
@java.lang.Override
public Builder mergeFrom(com.google.protobuf.Message other) {
if (other instanceof tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.FromServer) {
return mergeFrom((tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.FromServer)other);
} else {
super.mergeFrom(other);
return this;
}
}
public Builder mergeFrom(tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.FromServer other) {
if (other == tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.FromServer.getDefaultInstance()) return this;
if (other.status_ != 0) {
setStatusValue(other.getStatusValue());
}
if (issuesBuilder_ == null) {
if (!other.issues_.isEmpty()) {
if (issues_.isEmpty()) {
issues_ = other.issues_;
bitField0_ = (bitField0_ & ~0x00000002);
} else {
ensureIssuesIsMutable();
issues_.addAll(other.issues_);
}
onChanged();
}
} else {
if (!other.issues_.isEmpty()) {
if (issuesBuilder_.isEmpty()) {
issuesBuilder_.dispose();
issuesBuilder_ = null;
issues_ = other.issues_;
bitField0_ = (bitField0_ & ~0x00000002);
issuesBuilder_ =
com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders ?
getIssuesFieldBuilder() : null;
} else {
issuesBuilder_.addAllMessages(other.issues_);
}
}
}
switch (other.getServerMessageCase()) {
case INIT_RESPONSE: {
mergeInitResponse(other.getInitResponse());
break;
}
case WRITE_RESPONSE: {
mergeWriteResponse(other.getWriteResponse());
break;
}
case UPDATE_TOKEN_RESPONSE: {
mergeUpdateTokenResponse(other.getUpdateTokenResponse());
break;
}
case SERVERMESSAGE_NOT_SET: {
break;
}
}
this.mergeUnknownFields(other.getUnknownFields());
onChanged();
return this;
}
@java.lang.Override
public final boolean isInitialized() {
return true;
}
@java.lang.Override
public Builder mergeFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
if (extensionRegistry == null) {
throw new java.lang.NullPointerException();
}
try {
boolean done = false;
while (!done) {
int tag = input.readTag();
switch (tag) {
case 0:
done = true;
break;
case 8: {
status_ = input.readEnum();
bitField0_ |= 0x00000001;
break;
} // case 8
case 18: {
tech.ydb.proto.YdbIssueMessage.IssueMessage m =
input.readMessage(
tech.ydb.proto.YdbIssueMessage.IssueMessage.parser(),
extensionRegistry);
if (issuesBuilder_ == null) {
ensureIssuesIsMutable();
issues_.add(m);
} else {
issuesBuilder_.addMessage(m);
}
break;
} // case 18
case 26: {
input.readMessage(
getInitResponseFieldBuilder().getBuilder(),
extensionRegistry);
serverMessageCase_ = 3;
break;
} // case 26
case 34: {
input.readMessage(
getWriteResponseFieldBuilder().getBuilder(),
extensionRegistry);
serverMessageCase_ = 4;
break;
} // case 34
case 42: {
input.readMessage(
getUpdateTokenResponseFieldBuilder().getBuilder(),
extensionRegistry);
serverMessageCase_ = 5;
break;
} // case 42
default: {
if (!super.parseUnknownField(input, extensionRegistry, tag)) {
done = true; // was an endgroup tag
}
break;
} // default:
} // switch (tag)
} // while (!done)
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.unwrapIOException();
} finally {
onChanged();
} // finally
return this;
}
private int serverMessageCase_ = 0;
private java.lang.Object serverMessage_;
public ServerMessageCase
getServerMessageCase() {
return ServerMessageCase.forNumber(
serverMessageCase_);
}
public Builder clearServerMessage() {
serverMessageCase_ = 0;
serverMessage_ = null;
onChanged();
return this;
}
private int bitField0_;
private int status_ = 0;
/**
*
* Server status of response.
*
*
* .Ydb.StatusIds.StatusCode status = 1;
* @return The enum numeric value on the wire for status.
*/
@java.lang.Override public int getStatusValue() {
return status_;
}
/**
*
* Server status of response.
*
*
* .Ydb.StatusIds.StatusCode status = 1;
* @param value The enum numeric value on the wire for status to set.
* @return This builder for chaining.
*/
public Builder setStatusValue(int value) {
status_ = value;
bitField0_ |= 0x00000001;
onChanged();
return this;
}
/**
*
* Server status of response.
*
*
* .Ydb.StatusIds.StatusCode status = 1;
* @return The status.
*/
@java.lang.Override
public tech.ydb.proto.StatusCodesProtos.StatusIds.StatusCode getStatus() {
tech.ydb.proto.StatusCodesProtos.StatusIds.StatusCode result = tech.ydb.proto.StatusCodesProtos.StatusIds.StatusCode.forNumber(status_);
return result == null ? tech.ydb.proto.StatusCodesProtos.StatusIds.StatusCode.UNRECOGNIZED : result;
}
/**
*
* Server status of response.
*
*
* .Ydb.StatusIds.StatusCode status = 1;
* @param value The status to set.
* @return This builder for chaining.
*/
public Builder setStatus(tech.ydb.proto.StatusCodesProtos.StatusIds.StatusCode value) {
if (value == null) {
throw new NullPointerException();
}
bitField0_ |= 0x00000001;
status_ = value.getNumber();
onChanged();
return this;
}
/**
*
* Server status of response.
*
*
* .Ydb.StatusIds.StatusCode status = 1;
* @return This builder for chaining.
*/
public Builder clearStatus() {
bitField0_ = (bitField0_ & ~0x00000001);
status_ = 0;
onChanged();
return this;
}
private java.util.List issues_ =
java.util.Collections.emptyList();
private void ensureIssuesIsMutable() {
if (!((bitField0_ & 0x00000002) != 0)) {
issues_ = new java.util.ArrayList(issues_);
bitField0_ |= 0x00000002;
}
}
private com.google.protobuf.RepeatedFieldBuilderV3<
tech.ydb.proto.YdbIssueMessage.IssueMessage, tech.ydb.proto.YdbIssueMessage.IssueMessage.Builder, tech.ydb.proto.YdbIssueMessage.IssueMessageOrBuilder> issuesBuilder_;
/**
*
* Issues if any.
*
*
* repeated .Ydb.Issue.IssueMessage issues = 2;
*/
public java.util.List getIssuesList() {
if (issuesBuilder_ == null) {
return java.util.Collections.unmodifiableList(issues_);
} else {
return issuesBuilder_.getMessageList();
}
}
/**
*
* Issues if any.
*
*
* repeated .Ydb.Issue.IssueMessage issues = 2;
*/
public int getIssuesCount() {
if (issuesBuilder_ == null) {
return issues_.size();
} else {
return issuesBuilder_.getCount();
}
}
/**
*
* Issues if any.
*
*
* repeated .Ydb.Issue.IssueMessage issues = 2;
*/
public tech.ydb.proto.YdbIssueMessage.IssueMessage getIssues(int index) {
if (issuesBuilder_ == null) {
return issues_.get(index);
} else {
return issuesBuilder_.getMessage(index);
}
}
/**
*
* Issues if any.
*
*
* repeated .Ydb.Issue.IssueMessage issues = 2;
*/
public Builder setIssues(
int index, tech.ydb.proto.YdbIssueMessage.IssueMessage value) {
if (issuesBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
ensureIssuesIsMutable();
issues_.set(index, value);
onChanged();
} else {
issuesBuilder_.setMessage(index, value);
}
return this;
}
/**
*
* Issues if any.
*
*
* repeated .Ydb.Issue.IssueMessage issues = 2;
*/
public Builder setIssues(
int index, tech.ydb.proto.YdbIssueMessage.IssueMessage.Builder builderForValue) {
if (issuesBuilder_ == null) {
ensureIssuesIsMutable();
issues_.set(index, builderForValue.build());
onChanged();
} else {
issuesBuilder_.setMessage(index, builderForValue.build());
}
return this;
}
/**
*
* Issues if any.
*
*
* repeated .Ydb.Issue.IssueMessage issues = 2;
*/
public Builder addIssues(tech.ydb.proto.YdbIssueMessage.IssueMessage value) {
if (issuesBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
ensureIssuesIsMutable();
issues_.add(value);
onChanged();
} else {
issuesBuilder_.addMessage(value);
}
return this;
}
/**
*
* Issues if any.
*
*
* repeated .Ydb.Issue.IssueMessage issues = 2;
*/
public Builder addIssues(
int index, tech.ydb.proto.YdbIssueMessage.IssueMessage value) {
if (issuesBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
ensureIssuesIsMutable();
issues_.add(index, value);
onChanged();
} else {
issuesBuilder_.addMessage(index, value);
}
return this;
}
/**
*
* Issues if any.
*
*
* repeated .Ydb.Issue.IssueMessage issues = 2;
*/
public Builder addIssues(
tech.ydb.proto.YdbIssueMessage.IssueMessage.Builder builderForValue) {
if (issuesBuilder_ == null) {
ensureIssuesIsMutable();
issues_.add(builderForValue.build());
onChanged();
} else {
issuesBuilder_.addMessage(builderForValue.build());
}
return this;
}
/**
*
* Issues if any.
*
*
* repeated .Ydb.Issue.IssueMessage issues = 2;
*/
public Builder addIssues(
int index, tech.ydb.proto.YdbIssueMessage.IssueMessage.Builder builderForValue) {
if (issuesBuilder_ == null) {
ensureIssuesIsMutable();
issues_.add(index, builderForValue.build());
onChanged();
} else {
issuesBuilder_.addMessage(index, builderForValue.build());
}
return this;
}
/**
*
* Issues if any.
*
*
* repeated .Ydb.Issue.IssueMessage issues = 2;
*/
public Builder addAllIssues(
java.lang.Iterable extends tech.ydb.proto.YdbIssueMessage.IssueMessage> values) {
if (issuesBuilder_ == null) {
ensureIssuesIsMutable();
com.google.protobuf.AbstractMessageLite.Builder.addAll(
values, issues_);
onChanged();
} else {
issuesBuilder_.addAllMessages(values);
}
return this;
}
/**
*
* Issues if any.
*
*
* repeated .Ydb.Issue.IssueMessage issues = 2;
*/
public Builder clearIssues() {
if (issuesBuilder_ == null) {
issues_ = java.util.Collections.emptyList();
bitField0_ = (bitField0_ & ~0x00000002);
onChanged();
} else {
issuesBuilder_.clear();
}
return this;
}
/**
*
* Issues if any.
*
*
* repeated .Ydb.Issue.IssueMessage issues = 2;
*/
public Builder removeIssues(int index) {
if (issuesBuilder_ == null) {
ensureIssuesIsMutable();
issues_.remove(index);
onChanged();
} else {
issuesBuilder_.remove(index);
}
return this;
}
/**
*
* Issues if any.
*
*
* repeated .Ydb.Issue.IssueMessage issues = 2;
*/
public tech.ydb.proto.YdbIssueMessage.IssueMessage.Builder getIssuesBuilder(
int index) {
return getIssuesFieldBuilder().getBuilder(index);
}
/**
*
* Issues if any.
*
*
* repeated .Ydb.Issue.IssueMessage issues = 2;
*/
public tech.ydb.proto.YdbIssueMessage.IssueMessageOrBuilder getIssuesOrBuilder(
int index) {
if (issuesBuilder_ == null) {
return issues_.get(index); } else {
return issuesBuilder_.getMessageOrBuilder(index);
}
}
/**
*
* Issues if any.
*
*
* repeated .Ydb.Issue.IssueMessage issues = 2;
*/
public java.util.List extends tech.ydb.proto.YdbIssueMessage.IssueMessageOrBuilder>
getIssuesOrBuilderList() {
if (issuesBuilder_ != null) {
return issuesBuilder_.getMessageOrBuilderList();
} else {
return java.util.Collections.unmodifiableList(issues_);
}
}
/**
*
* Issues if any.
*
*
* repeated .Ydb.Issue.IssueMessage issues = 2;
*/
public tech.ydb.proto.YdbIssueMessage.IssueMessage.Builder addIssuesBuilder() {
return getIssuesFieldBuilder().addBuilder(
tech.ydb.proto.YdbIssueMessage.IssueMessage.getDefaultInstance());
}
/**
*
* Issues if any.
*
*
* repeated .Ydb.Issue.IssueMessage issues = 2;
*/
public tech.ydb.proto.YdbIssueMessage.IssueMessage.Builder addIssuesBuilder(
int index) {
return getIssuesFieldBuilder().addBuilder(
index, tech.ydb.proto.YdbIssueMessage.IssueMessage.getDefaultInstance());
}
/**
*
* Issues if any.
*
*
* repeated .Ydb.Issue.IssueMessage issues = 2;
*/
public java.util.List
getIssuesBuilderList() {
return getIssuesFieldBuilder().getBuilderList();
}
private com.google.protobuf.RepeatedFieldBuilderV3<
tech.ydb.proto.YdbIssueMessage.IssueMessage, tech.ydb.proto.YdbIssueMessage.IssueMessage.Builder, tech.ydb.proto.YdbIssueMessage.IssueMessageOrBuilder>
getIssuesFieldBuilder() {
if (issuesBuilder_ == null) {
issuesBuilder_ = new com.google.protobuf.RepeatedFieldBuilderV3<
tech.ydb.proto.YdbIssueMessage.IssueMessage, tech.ydb.proto.YdbIssueMessage.IssueMessage.Builder, tech.ydb.proto.YdbIssueMessage.IssueMessageOrBuilder>(
issues_,
((bitField0_ & 0x00000002) != 0),
getParentForChildren(),
isClean());
issues_ = null;
}
return issuesBuilder_;
}
private com.google.protobuf.SingleFieldBuilderV3<
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitResponse, tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitResponse.Builder, tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitResponseOrBuilder> initResponseBuilder_;
/**
* .Ydb.Topic.StreamWriteMessage.InitResponse init_response = 3;
* @return Whether the initResponse field is set.
*/
@java.lang.Override
public boolean hasInitResponse() {
return serverMessageCase_ == 3;
}
/**
* .Ydb.Topic.StreamWriteMessage.InitResponse init_response = 3;
* @return The initResponse.
*/
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitResponse getInitResponse() {
if (initResponseBuilder_ == null) {
if (serverMessageCase_ == 3) {
return (tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitResponse) serverMessage_;
}
return tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitResponse.getDefaultInstance();
} else {
if (serverMessageCase_ == 3) {
return initResponseBuilder_.getMessage();
}
return tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitResponse.getDefaultInstance();
}
}
/**
* .Ydb.Topic.StreamWriteMessage.InitResponse init_response = 3;
*/
public Builder setInitResponse(tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitResponse value) {
if (initResponseBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
serverMessage_ = value;
onChanged();
} else {
initResponseBuilder_.setMessage(value);
}
serverMessageCase_ = 3;
return this;
}
/**
* .Ydb.Topic.StreamWriteMessage.InitResponse init_response = 3;
*/
public Builder setInitResponse(
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitResponse.Builder builderForValue) {
if (initResponseBuilder_ == null) {
serverMessage_ = builderForValue.build();
onChanged();
} else {
initResponseBuilder_.setMessage(builderForValue.build());
}
serverMessageCase_ = 3;
return this;
}
/**
* .Ydb.Topic.StreamWriteMessage.InitResponse init_response = 3;
*/
public Builder mergeInitResponse(tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitResponse value) {
if (initResponseBuilder_ == null) {
if (serverMessageCase_ == 3 &&
serverMessage_ != tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitResponse.getDefaultInstance()) {
serverMessage_ = tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitResponse.newBuilder((tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitResponse) serverMessage_)
.mergeFrom(value).buildPartial();
} else {
serverMessage_ = value;
}
onChanged();
} else {
if (serverMessageCase_ == 3) {
initResponseBuilder_.mergeFrom(value);
} else {
initResponseBuilder_.setMessage(value);
}
}
serverMessageCase_ = 3;
return this;
}
/**
* .Ydb.Topic.StreamWriteMessage.InitResponse init_response = 3;
*/
public Builder clearInitResponse() {
if (initResponseBuilder_ == null) {
if (serverMessageCase_ == 3) {
serverMessageCase_ = 0;
serverMessage_ = null;
onChanged();
}
} else {
if (serverMessageCase_ == 3) {
serverMessageCase_ = 0;
serverMessage_ = null;
}
initResponseBuilder_.clear();
}
return this;
}
/**
* .Ydb.Topic.StreamWriteMessage.InitResponse init_response = 3;
*/
public tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitResponse.Builder getInitResponseBuilder() {
return getInitResponseFieldBuilder().getBuilder();
}
/**
* .Ydb.Topic.StreamWriteMessage.InitResponse init_response = 3;
*/
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitResponseOrBuilder getInitResponseOrBuilder() {
if ((serverMessageCase_ == 3) && (initResponseBuilder_ != null)) {
return initResponseBuilder_.getMessageOrBuilder();
} else {
if (serverMessageCase_ == 3) {
return (tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitResponse) serverMessage_;
}
return tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitResponse.getDefaultInstance();
}
}
/**
* .Ydb.Topic.StreamWriteMessage.InitResponse init_response = 3;
*/
private com.google.protobuf.SingleFieldBuilderV3<
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitResponse, tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitResponse.Builder, tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitResponseOrBuilder>
getInitResponseFieldBuilder() {
if (initResponseBuilder_ == null) {
if (!(serverMessageCase_ == 3)) {
serverMessage_ = tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitResponse.getDefaultInstance();
}
initResponseBuilder_ = new com.google.protobuf.SingleFieldBuilderV3<
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitResponse, tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitResponse.Builder, tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitResponseOrBuilder>(
(tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitResponse) serverMessage_,
getParentForChildren(),
isClean());
serverMessage_ = null;
}
serverMessageCase_ = 3;
onChanged();
return initResponseBuilder_;
}
private com.google.protobuf.SingleFieldBuilderV3<
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse, tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.Builder, tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponseOrBuilder> writeResponseBuilder_;
/**
* .Ydb.Topic.StreamWriteMessage.WriteResponse write_response = 4;
* @return Whether the writeResponse field is set.
*/
@java.lang.Override
public boolean hasWriteResponse() {
return serverMessageCase_ == 4;
}
/**
* .Ydb.Topic.StreamWriteMessage.WriteResponse write_response = 4;
* @return The writeResponse.
*/
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse getWriteResponse() {
if (writeResponseBuilder_ == null) {
if (serverMessageCase_ == 4) {
return (tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse) serverMessage_;
}
return tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.getDefaultInstance();
} else {
if (serverMessageCase_ == 4) {
return writeResponseBuilder_.getMessage();
}
return tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.getDefaultInstance();
}
}
/**
* .Ydb.Topic.StreamWriteMessage.WriteResponse write_response = 4;
*/
public Builder setWriteResponse(tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse value) {
if (writeResponseBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
serverMessage_ = value;
onChanged();
} else {
writeResponseBuilder_.setMessage(value);
}
serverMessageCase_ = 4;
return this;
}
/**
* .Ydb.Topic.StreamWriteMessage.WriteResponse write_response = 4;
*/
public Builder setWriteResponse(
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.Builder builderForValue) {
if (writeResponseBuilder_ == null) {
serverMessage_ = builderForValue.build();
onChanged();
} else {
writeResponseBuilder_.setMessage(builderForValue.build());
}
serverMessageCase_ = 4;
return this;
}
/**
* .Ydb.Topic.StreamWriteMessage.WriteResponse write_response = 4;
*/
public Builder mergeWriteResponse(tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse value) {
if (writeResponseBuilder_ == null) {
if (serverMessageCase_ == 4 &&
serverMessage_ != tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.getDefaultInstance()) {
serverMessage_ = tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.newBuilder((tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse) serverMessage_)
.mergeFrom(value).buildPartial();
} else {
serverMessage_ = value;
}
onChanged();
} else {
if (serverMessageCase_ == 4) {
writeResponseBuilder_.mergeFrom(value);
} else {
writeResponseBuilder_.setMessage(value);
}
}
serverMessageCase_ = 4;
return this;
}
/**
* .Ydb.Topic.StreamWriteMessage.WriteResponse write_response = 4;
*/
public Builder clearWriteResponse() {
if (writeResponseBuilder_ == null) {
if (serverMessageCase_ == 4) {
serverMessageCase_ = 0;
serverMessage_ = null;
onChanged();
}
} else {
if (serverMessageCase_ == 4) {
serverMessageCase_ = 0;
serverMessage_ = null;
}
writeResponseBuilder_.clear();
}
return this;
}
/**
* .Ydb.Topic.StreamWriteMessage.WriteResponse write_response = 4;
*/
public tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.Builder getWriteResponseBuilder() {
return getWriteResponseFieldBuilder().getBuilder();
}
/**
* .Ydb.Topic.StreamWriteMessage.WriteResponse write_response = 4;
*/
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponseOrBuilder getWriteResponseOrBuilder() {
if ((serverMessageCase_ == 4) && (writeResponseBuilder_ != null)) {
return writeResponseBuilder_.getMessageOrBuilder();
} else {
if (serverMessageCase_ == 4) {
return (tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse) serverMessage_;
}
return tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.getDefaultInstance();
}
}
/**
* .Ydb.Topic.StreamWriteMessage.WriteResponse write_response = 4;
*/
private com.google.protobuf.SingleFieldBuilderV3<
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse, tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.Builder, tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponseOrBuilder>
getWriteResponseFieldBuilder() {
if (writeResponseBuilder_ == null) {
if (!(serverMessageCase_ == 4)) {
serverMessage_ = tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.getDefaultInstance();
}
writeResponseBuilder_ = new com.google.protobuf.SingleFieldBuilderV3<
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse, tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.Builder, tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponseOrBuilder>(
(tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse) serverMessage_,
getParentForChildren(),
isClean());
serverMessage_ = null;
}
serverMessageCase_ = 4;
onChanged();
return writeResponseBuilder_;
}
private com.google.protobuf.SingleFieldBuilderV3<
tech.ydb.proto.topic.YdbTopic.UpdateTokenResponse, tech.ydb.proto.topic.YdbTopic.UpdateTokenResponse.Builder, tech.ydb.proto.topic.YdbTopic.UpdateTokenResponseOrBuilder> updateTokenResponseBuilder_;
/**
* .Ydb.Topic.UpdateTokenResponse update_token_response = 5;
* @return Whether the updateTokenResponse field is set.
*/
@java.lang.Override
public boolean hasUpdateTokenResponse() {
return serverMessageCase_ == 5;
}
/**
* .Ydb.Topic.UpdateTokenResponse update_token_response = 5;
* @return The updateTokenResponse.
*/
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.UpdateTokenResponse getUpdateTokenResponse() {
if (updateTokenResponseBuilder_ == null) {
if (serverMessageCase_ == 5) {
return (tech.ydb.proto.topic.YdbTopic.UpdateTokenResponse) serverMessage_;
}
return tech.ydb.proto.topic.YdbTopic.UpdateTokenResponse.getDefaultInstance();
} else {
if (serverMessageCase_ == 5) {
return updateTokenResponseBuilder_.getMessage();
}
return tech.ydb.proto.topic.YdbTopic.UpdateTokenResponse.getDefaultInstance();
}
}
/**
* .Ydb.Topic.UpdateTokenResponse update_token_response = 5;
*/
public Builder setUpdateTokenResponse(tech.ydb.proto.topic.YdbTopic.UpdateTokenResponse value) {
if (updateTokenResponseBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
serverMessage_ = value;
onChanged();
} else {
updateTokenResponseBuilder_.setMessage(value);
}
serverMessageCase_ = 5;
return this;
}
/**
* .Ydb.Topic.UpdateTokenResponse update_token_response = 5;
*/
public Builder setUpdateTokenResponse(
tech.ydb.proto.topic.YdbTopic.UpdateTokenResponse.Builder builderForValue) {
if (updateTokenResponseBuilder_ == null) {
serverMessage_ = builderForValue.build();
onChanged();
} else {
updateTokenResponseBuilder_.setMessage(builderForValue.build());
}
serverMessageCase_ = 5;
return this;
}
/**
* .Ydb.Topic.UpdateTokenResponse update_token_response = 5;
*/
public Builder mergeUpdateTokenResponse(tech.ydb.proto.topic.YdbTopic.UpdateTokenResponse value) {
if (updateTokenResponseBuilder_ == null) {
if (serverMessageCase_ == 5 &&
serverMessage_ != tech.ydb.proto.topic.YdbTopic.UpdateTokenResponse.getDefaultInstance()) {
serverMessage_ = tech.ydb.proto.topic.YdbTopic.UpdateTokenResponse.newBuilder((tech.ydb.proto.topic.YdbTopic.UpdateTokenResponse) serverMessage_)
.mergeFrom(value).buildPartial();
} else {
serverMessage_ = value;
}
onChanged();
} else {
if (serverMessageCase_ == 5) {
updateTokenResponseBuilder_.mergeFrom(value);
} else {
updateTokenResponseBuilder_.setMessage(value);
}
}
serverMessageCase_ = 5;
return this;
}
/**
* .Ydb.Topic.UpdateTokenResponse update_token_response = 5;
*/
public Builder clearUpdateTokenResponse() {
if (updateTokenResponseBuilder_ == null) {
if (serverMessageCase_ == 5) {
serverMessageCase_ = 0;
serverMessage_ = null;
onChanged();
}
} else {
if (serverMessageCase_ == 5) {
serverMessageCase_ = 0;
serverMessage_ = null;
}
updateTokenResponseBuilder_.clear();
}
return this;
}
/**
* .Ydb.Topic.UpdateTokenResponse update_token_response = 5;
*/
public tech.ydb.proto.topic.YdbTopic.UpdateTokenResponse.Builder getUpdateTokenResponseBuilder() {
return getUpdateTokenResponseFieldBuilder().getBuilder();
}
/**
* .Ydb.Topic.UpdateTokenResponse update_token_response = 5;
*/
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.UpdateTokenResponseOrBuilder getUpdateTokenResponseOrBuilder() {
if ((serverMessageCase_ == 5) && (updateTokenResponseBuilder_ != null)) {
return updateTokenResponseBuilder_.getMessageOrBuilder();
} else {
if (serverMessageCase_ == 5) {
return (tech.ydb.proto.topic.YdbTopic.UpdateTokenResponse) serverMessage_;
}
return tech.ydb.proto.topic.YdbTopic.UpdateTokenResponse.getDefaultInstance();
}
}
/**
* .Ydb.Topic.UpdateTokenResponse update_token_response = 5;
*/
private com.google.protobuf.SingleFieldBuilderV3<
tech.ydb.proto.topic.YdbTopic.UpdateTokenResponse, tech.ydb.proto.topic.YdbTopic.UpdateTokenResponse.Builder, tech.ydb.proto.topic.YdbTopic.UpdateTokenResponseOrBuilder>
getUpdateTokenResponseFieldBuilder() {
if (updateTokenResponseBuilder_ == null) {
if (!(serverMessageCase_ == 5)) {
serverMessage_ = tech.ydb.proto.topic.YdbTopic.UpdateTokenResponse.getDefaultInstance();
}
updateTokenResponseBuilder_ = new com.google.protobuf.SingleFieldBuilderV3<
tech.ydb.proto.topic.YdbTopic.UpdateTokenResponse, tech.ydb.proto.topic.YdbTopic.UpdateTokenResponse.Builder, tech.ydb.proto.topic.YdbTopic.UpdateTokenResponseOrBuilder>(
(tech.ydb.proto.topic.YdbTopic.UpdateTokenResponse) serverMessage_,
getParentForChildren(),
isClean());
serverMessage_ = null;
}
serverMessageCase_ = 5;
onChanged();
return updateTokenResponseBuilder_;
}
@java.lang.Override
public final Builder setUnknownFields(
final com.google.protobuf.UnknownFieldSet unknownFields) {
return super.setUnknownFields(unknownFields);
}
@java.lang.Override
public final Builder mergeUnknownFields(
final com.google.protobuf.UnknownFieldSet unknownFields) {
return super.mergeUnknownFields(unknownFields);
}
// @@protoc_insertion_point(builder_scope:Ydb.Topic.StreamWriteMessage.FromServer)
}
// @@protoc_insertion_point(class_scope:Ydb.Topic.StreamWriteMessage.FromServer)
private static final tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.FromServer DEFAULT_INSTANCE;
static {
DEFAULT_INSTANCE = new tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.FromServer();
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.FromServer getDefaultInstance() {
return DEFAULT_INSTANCE;
}
private static final com.google.protobuf.Parser
PARSER = new com.google.protobuf.AbstractParser() {
@java.lang.Override
public FromServer parsePartialFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
Builder builder = newBuilder();
try {
builder.mergeFrom(input, extensionRegistry);
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.setUnfinishedMessage(builder.buildPartial());
} catch (com.google.protobuf.UninitializedMessageException e) {
throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial());
} catch (java.io.IOException e) {
throw new com.google.protobuf.InvalidProtocolBufferException(e)
.setUnfinishedMessage(builder.buildPartial());
}
return builder.buildPartial();
}
};
public static com.google.protobuf.Parser parser() {
return PARSER;
}
@java.lang.Override
public com.google.protobuf.Parser getParserForType() {
return PARSER;
}
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.FromServer getDefaultInstanceForType() {
return DEFAULT_INSTANCE;
}
}
public interface InitRequestOrBuilder extends
// @@protoc_insertion_point(interface_extends:Ydb.Topic.StreamWriteMessage.InitRequest)
com.google.protobuf.MessageOrBuilder {
/**
*
* Full path of topic to write to.
*
*
* string path = 1;
* @return The path.
*/
java.lang.String getPath();
/**
*
* Full path of topic to write to.
*
*
* string path = 1;
* @return The bytes for path.
*/
com.google.protobuf.ByteString
getPathBytes();
/**
*
* Producer identifier of client data stream.
* Used for message deduplication by sequence numbers.
*
*
* string producer_id = 2 [(.Ydb.length) = { ... }
* @return The producerId.
*/
java.lang.String getProducerId();
/**
*
* Producer identifier of client data stream.
* Used for message deduplication by sequence numbers.
*
*
* string producer_id = 2 [(.Ydb.length) = { ... }
* @return The bytes for producerId.
*/
com.google.protobuf.ByteString
getProducerIdBytes();
/**
*
* User metadata attached to this write session.
* Reader will get this session meta data with each message read.
*
*
* map<string, string> write_session_meta = 3;
*/
int getWriteSessionMetaCount();
/**
*
* User metadata attached to this write session.
* Reader will get this session meta data with each message read.
*
*
* map<string, string> write_session_meta = 3;
*/
boolean containsWriteSessionMeta(
java.lang.String key);
/**
* Use {@link #getWriteSessionMetaMap()} instead.
*/
@java.lang.Deprecated
java.util.Map
getWriteSessionMeta();
/**
*
* User metadata attached to this write session.
* Reader will get this session meta data with each message read.
*
*
* map<string, string> write_session_meta = 3;
*/
java.util.Map
getWriteSessionMetaMap();
/**
*
* User metadata attached to this write session.
* Reader will get this session meta data with each message read.
*
*
* map<string, string> write_session_meta = 3;
*/
/* nullable */
java.lang.String getWriteSessionMetaOrDefault(
java.lang.String key,
/* nullable */
java.lang.String defaultValue);
/**
*
* User metadata attached to this write session.
* Reader will get this session meta data with each message read.
*
*
* map<string, string> write_session_meta = 3;
*/
java.lang.String getWriteSessionMetaOrThrow(
java.lang.String key);
/**
*
* All messages with given pair (producer_id, message_group_id) go to single partition in order of writes.
*
*
* string message_group_id = 4 [(.Ydb.length) = { ... }
* @return Whether the messageGroupId field is set.
*/
boolean hasMessageGroupId();
/**
*
* All messages with given pair (producer_id, message_group_id) go to single partition in order of writes.
*
*
* string message_group_id = 4 [(.Ydb.length) = { ... }
* @return The messageGroupId.
*/
java.lang.String getMessageGroupId();
/**
*
* All messages with given pair (producer_id, message_group_id) go to single partition in order of writes.
*
*
* string message_group_id = 4 [(.Ydb.length) = { ... }
* @return The bytes for messageGroupId.
*/
com.google.protobuf.ByteString
getMessageGroupIdBytes();
/**
*
* Explicit partition id to write to.
*
*
* int64 partition_id = 5;
* @return Whether the partitionId field is set.
*/
boolean hasPartitionId();
/**
*
* Explicit partition id to write to.
*
*
* int64 partition_id = 5;
* @return The partitionId.
*/
long getPartitionId();
/**
*
* Explicit partition location to write to.
*
*
* .Ydb.Topic.PartitionWithGeneration partition_with_generation = 7;
* @return Whether the partitionWithGeneration field is set.
*/
boolean hasPartitionWithGeneration();
/**
*
* Explicit partition location to write to.
*
*
* .Ydb.Topic.PartitionWithGeneration partition_with_generation = 7;
* @return The partitionWithGeneration.
*/
tech.ydb.proto.topic.YdbTopic.PartitionWithGeneration getPartitionWithGeneration();
/**
*
* Explicit partition location to write to.
*
*
* .Ydb.Topic.PartitionWithGeneration partition_with_generation = 7;
*/
tech.ydb.proto.topic.YdbTopic.PartitionWithGenerationOrBuilder getPartitionWithGenerationOrBuilder();
/**
*
* Explicitly request for last sequential number
* It may be expensive, if producer wrote to many partitions before.
*
*
* bool get_last_seq_no = 6;
* @return The getLastSeqNo.
*/
boolean getGetLastSeqNo();
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitRequest.PartitioningCase getPartitioningCase();
}
/**
*
* Handshake request that must be sent to server first.
*
*
* Protobuf type {@code Ydb.Topic.StreamWriteMessage.InitRequest}
*/
public static final class InitRequest extends
com.google.protobuf.GeneratedMessageV3 implements
// @@protoc_insertion_point(message_implements:Ydb.Topic.StreamWriteMessage.InitRequest)
InitRequestOrBuilder {
private static final long serialVersionUID = 0L;
// Use InitRequest.newBuilder() to construct.
private InitRequest(com.google.protobuf.GeneratedMessageV3.Builder> builder) {
super(builder);
}
private InitRequest() {
path_ = "";
producerId_ = "";
}
@java.lang.Override
@SuppressWarnings({"unused"})
protected java.lang.Object newInstance(
UnusedPrivateParameter unused) {
return new InitRequest();
}
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_StreamWriteMessage_InitRequest_descriptor;
}
@SuppressWarnings({"rawtypes"})
@java.lang.Override
protected com.google.protobuf.MapField internalGetMapField(
int number) {
switch (number) {
case 3:
return internalGetWriteSessionMeta();
default:
throw new RuntimeException(
"Invalid map field number: " + number);
}
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_StreamWriteMessage_InitRequest_fieldAccessorTable
.ensureFieldAccessorsInitialized(
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitRequest.class, tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitRequest.Builder.class);
}
private int partitioningCase_ = 0;
@SuppressWarnings("serial")
private java.lang.Object partitioning_;
public enum PartitioningCase
implements com.google.protobuf.Internal.EnumLite,
com.google.protobuf.AbstractMessage.InternalOneOfEnum {
MESSAGE_GROUP_ID(4),
PARTITION_ID(5),
PARTITION_WITH_GENERATION(7),
PARTITIONING_NOT_SET(0);
private final int value;
private PartitioningCase(int value) {
this.value = value;
}
/**
* @param value The number of the enum to look for.
* @return The enum associated with the given number.
* @deprecated Use {@link #forNumber(int)} instead.
*/
@java.lang.Deprecated
public static PartitioningCase valueOf(int value) {
return forNumber(value);
}
public static PartitioningCase forNumber(int value) {
switch (value) {
case 4: return MESSAGE_GROUP_ID;
case 5: return PARTITION_ID;
case 7: return PARTITION_WITH_GENERATION;
case 0: return PARTITIONING_NOT_SET;
default: return null;
}
}
public int getNumber() {
return this.value;
}
};
public PartitioningCase
getPartitioningCase() {
return PartitioningCase.forNumber(
partitioningCase_);
}
public static final int PATH_FIELD_NUMBER = 1;
@SuppressWarnings("serial")
private volatile java.lang.Object path_ = "";
/**
*
* Full path of topic to write to.
*
*
* string path = 1;
* @return The path.
*/
@java.lang.Override
public java.lang.String getPath() {
java.lang.Object ref = path_;
if (ref instanceof java.lang.String) {
return (java.lang.String) ref;
} else {
com.google.protobuf.ByteString bs =
(com.google.protobuf.ByteString) ref;
java.lang.String s = bs.toStringUtf8();
path_ = s;
return s;
}
}
/**
*
* Full path of topic to write to.
*
*
* string path = 1;
* @return The bytes for path.
*/
@java.lang.Override
public com.google.protobuf.ByteString
getPathBytes() {
java.lang.Object ref = path_;
if (ref instanceof java.lang.String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
path_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
public static final int PRODUCER_ID_FIELD_NUMBER = 2;
@SuppressWarnings("serial")
private volatile java.lang.Object producerId_ = "";
/**
*
* Producer identifier of client data stream.
* Used for message deduplication by sequence numbers.
*
*
* string producer_id = 2 [(.Ydb.length) = { ... }
* @return The producerId.
*/
@java.lang.Override
public java.lang.String getProducerId() {
java.lang.Object ref = producerId_;
if (ref instanceof java.lang.String) {
return (java.lang.String) ref;
} else {
com.google.protobuf.ByteString bs =
(com.google.protobuf.ByteString) ref;
java.lang.String s = bs.toStringUtf8();
producerId_ = s;
return s;
}
}
/**
*
* Producer identifier of client data stream.
* Used for message deduplication by sequence numbers.
*
*
* string producer_id = 2 [(.Ydb.length) = { ... }
* @return The bytes for producerId.
*/
@java.lang.Override
public com.google.protobuf.ByteString
getProducerIdBytes() {
java.lang.Object ref = producerId_;
if (ref instanceof java.lang.String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
producerId_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
public static final int WRITE_SESSION_META_FIELD_NUMBER = 3;
private static final class WriteSessionMetaDefaultEntryHolder {
static final com.google.protobuf.MapEntry<
java.lang.String, java.lang.String> defaultEntry =
com.google.protobuf.MapEntry
.newDefaultInstance(
tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_StreamWriteMessage_InitRequest_WriteSessionMetaEntry_descriptor,
com.google.protobuf.WireFormat.FieldType.STRING,
"",
com.google.protobuf.WireFormat.FieldType.STRING,
"");
}
@SuppressWarnings("serial")
private com.google.protobuf.MapField<
java.lang.String, java.lang.String> writeSessionMeta_;
private com.google.protobuf.MapField
internalGetWriteSessionMeta() {
if (writeSessionMeta_ == null) {
return com.google.protobuf.MapField.emptyMapField(
WriteSessionMetaDefaultEntryHolder.defaultEntry);
}
return writeSessionMeta_;
}
public int getWriteSessionMetaCount() {
return internalGetWriteSessionMeta().getMap().size();
}
/**
*
* User metadata attached to this write session.
* Reader will get this session meta data with each message read.
*
*
* map<string, string> write_session_meta = 3;
*/
@java.lang.Override
public boolean containsWriteSessionMeta(
java.lang.String key) {
if (key == null) { throw new NullPointerException("map key"); }
return internalGetWriteSessionMeta().getMap().containsKey(key);
}
/**
* Use {@link #getWriteSessionMetaMap()} instead.
*/
@java.lang.Override
@java.lang.Deprecated
public java.util.Map getWriteSessionMeta() {
return getWriteSessionMetaMap();
}
/**
*
* User metadata attached to this write session.
* Reader will get this session meta data with each message read.
*
*
* map<string, string> write_session_meta = 3;
*/
@java.lang.Override
public java.util.Map getWriteSessionMetaMap() {
return internalGetWriteSessionMeta().getMap();
}
/**
*
* User metadata attached to this write session.
* Reader will get this session meta data with each message read.
*
*
* map<string, string> write_session_meta = 3;
*/
@java.lang.Override
public /* nullable */
java.lang.String getWriteSessionMetaOrDefault(
java.lang.String key,
/* nullable */
java.lang.String defaultValue) {
if (key == null) { throw new NullPointerException("map key"); }
java.util.Map map =
internalGetWriteSessionMeta().getMap();
return map.containsKey(key) ? map.get(key) : defaultValue;
}
/**
*
* User metadata attached to this write session.
* Reader will get this session meta data with each message read.
*
*
* map<string, string> write_session_meta = 3;
*/
@java.lang.Override
public java.lang.String getWriteSessionMetaOrThrow(
java.lang.String key) {
if (key == null) { throw new NullPointerException("map key"); }
java.util.Map map =
internalGetWriteSessionMeta().getMap();
if (!map.containsKey(key)) {
throw new java.lang.IllegalArgumentException();
}
return map.get(key);
}
public static final int MESSAGE_GROUP_ID_FIELD_NUMBER = 4;
/**
*
* All messages with given pair (producer_id, message_group_id) go to single partition in order of writes.
*
*
* string message_group_id = 4 [(.Ydb.length) = { ... }
* @return Whether the messageGroupId field is set.
*/
public boolean hasMessageGroupId() {
return partitioningCase_ == 4;
}
/**
*
* All messages with given pair (producer_id, message_group_id) go to single partition in order of writes.
*
*
* string message_group_id = 4 [(.Ydb.length) = { ... }
* @return The messageGroupId.
*/
public java.lang.String getMessageGroupId() {
java.lang.Object ref = "";
if (partitioningCase_ == 4) {
ref = partitioning_;
}
if (ref instanceof java.lang.String) {
return (java.lang.String) ref;
} else {
com.google.protobuf.ByteString bs =
(com.google.protobuf.ByteString) ref;
java.lang.String s = bs.toStringUtf8();
if (partitioningCase_ == 4) {
partitioning_ = s;
}
return s;
}
}
/**
*
* All messages with given pair (producer_id, message_group_id) go to single partition in order of writes.
*
*
* string message_group_id = 4 [(.Ydb.length) = { ... }
* @return The bytes for messageGroupId.
*/
public com.google.protobuf.ByteString
getMessageGroupIdBytes() {
java.lang.Object ref = "";
if (partitioningCase_ == 4) {
ref = partitioning_;
}
if (ref instanceof java.lang.String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
if (partitioningCase_ == 4) {
partitioning_ = b;
}
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
public static final int PARTITION_ID_FIELD_NUMBER = 5;
/**
*
* Explicit partition id to write to.
*
*
* int64 partition_id = 5;
* @return Whether the partitionId field is set.
*/
@java.lang.Override
public boolean hasPartitionId() {
return partitioningCase_ == 5;
}
/**
*
* Explicit partition id to write to.
*
*
* int64 partition_id = 5;
* @return The partitionId.
*/
@java.lang.Override
public long getPartitionId() {
if (partitioningCase_ == 5) {
return (java.lang.Long) partitioning_;
}
return 0L;
}
public static final int PARTITION_WITH_GENERATION_FIELD_NUMBER = 7;
/**
*
* Explicit partition location to write to.
*
*
* .Ydb.Topic.PartitionWithGeneration partition_with_generation = 7;
* @return Whether the partitionWithGeneration field is set.
*/
@java.lang.Override
public boolean hasPartitionWithGeneration() {
return partitioningCase_ == 7;
}
/**
*
* Explicit partition location to write to.
*
*
* .Ydb.Topic.PartitionWithGeneration partition_with_generation = 7;
* @return The partitionWithGeneration.
*/
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.PartitionWithGeneration getPartitionWithGeneration() {
if (partitioningCase_ == 7) {
return (tech.ydb.proto.topic.YdbTopic.PartitionWithGeneration) partitioning_;
}
return tech.ydb.proto.topic.YdbTopic.PartitionWithGeneration.getDefaultInstance();
}
/**
*
* Explicit partition location to write to.
*
*
* .Ydb.Topic.PartitionWithGeneration partition_with_generation = 7;
*/
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.PartitionWithGenerationOrBuilder getPartitionWithGenerationOrBuilder() {
if (partitioningCase_ == 7) {
return (tech.ydb.proto.topic.YdbTopic.PartitionWithGeneration) partitioning_;
}
return tech.ydb.proto.topic.YdbTopic.PartitionWithGeneration.getDefaultInstance();
}
public static final int GET_LAST_SEQ_NO_FIELD_NUMBER = 6;
private boolean getLastSeqNo_ = false;
/**
*
* Explicitly request for last sequential number
* It may be expensive, if producer wrote to many partitions before.
*
*
* bool get_last_seq_no = 6;
* @return The getLastSeqNo.
*/
@java.lang.Override
public boolean getGetLastSeqNo() {
return getLastSeqNo_;
}
private byte memoizedIsInitialized = -1;
@java.lang.Override
public final boolean isInitialized() {
byte isInitialized = memoizedIsInitialized;
if (isInitialized == 1) return true;
if (isInitialized == 0) return false;
memoizedIsInitialized = 1;
return true;
}
@java.lang.Override
public void writeTo(com.google.protobuf.CodedOutputStream output)
throws java.io.IOException {
if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(path_)) {
com.google.protobuf.GeneratedMessageV3.writeString(output, 1, path_);
}
if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(producerId_)) {
com.google.protobuf.GeneratedMessageV3.writeString(output, 2, producerId_);
}
com.google.protobuf.GeneratedMessageV3
.serializeStringMapTo(
output,
internalGetWriteSessionMeta(),
WriteSessionMetaDefaultEntryHolder.defaultEntry,
3);
if (partitioningCase_ == 4) {
com.google.protobuf.GeneratedMessageV3.writeString(output, 4, partitioning_);
}
if (partitioningCase_ == 5) {
output.writeInt64(
5, (long)((java.lang.Long) partitioning_));
}
if (getLastSeqNo_ != false) {
output.writeBool(6, getLastSeqNo_);
}
if (partitioningCase_ == 7) {
output.writeMessage(7, (tech.ydb.proto.topic.YdbTopic.PartitionWithGeneration) partitioning_);
}
getUnknownFields().writeTo(output);
}
@java.lang.Override
public int getSerializedSize() {
int size = memoizedSize;
if (size != -1) return size;
size = 0;
if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(path_)) {
size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, path_);
}
if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(producerId_)) {
size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, producerId_);
}
for (java.util.Map.Entry entry
: internalGetWriteSessionMeta().getMap().entrySet()) {
com.google.protobuf.MapEntry
writeSessionMeta__ = WriteSessionMetaDefaultEntryHolder.defaultEntry.newBuilderForType()
.setKey(entry.getKey())
.setValue(entry.getValue())
.build();
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(3, writeSessionMeta__);
}
if (partitioningCase_ == 4) {
size += com.google.protobuf.GeneratedMessageV3.computeStringSize(4, partitioning_);
}
if (partitioningCase_ == 5) {
size += com.google.protobuf.CodedOutputStream
.computeInt64Size(
5, (long)((java.lang.Long) partitioning_));
}
if (getLastSeqNo_ != false) {
size += com.google.protobuf.CodedOutputStream
.computeBoolSize(6, getLastSeqNo_);
}
if (partitioningCase_ == 7) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(7, (tech.ydb.proto.topic.YdbTopic.PartitionWithGeneration) partitioning_);
}
size += getUnknownFields().getSerializedSize();
memoizedSize = size;
return size;
}
@java.lang.Override
public boolean equals(final java.lang.Object obj) {
if (obj == this) {
return true;
}
if (!(obj instanceof tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitRequest)) {
return super.equals(obj);
}
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitRequest other = (tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitRequest) obj;
if (!getPath()
.equals(other.getPath())) return false;
if (!getProducerId()
.equals(other.getProducerId())) return false;
if (!internalGetWriteSessionMeta().equals(
other.internalGetWriteSessionMeta())) return false;
if (getGetLastSeqNo()
!= other.getGetLastSeqNo()) return false;
if (!getPartitioningCase().equals(other.getPartitioningCase())) return false;
switch (partitioningCase_) {
case 4:
if (!getMessageGroupId()
.equals(other.getMessageGroupId())) return false;
break;
case 5:
if (getPartitionId()
!= other.getPartitionId()) return false;
break;
case 7:
if (!getPartitionWithGeneration()
.equals(other.getPartitionWithGeneration())) return false;
break;
case 0:
default:
}
if (!getUnknownFields().equals(other.getUnknownFields())) return false;
return true;
}
@java.lang.Override
public int hashCode() {
if (memoizedHashCode != 0) {
return memoizedHashCode;
}
int hash = 41;
hash = (19 * hash) + getDescriptor().hashCode();
hash = (37 * hash) + PATH_FIELD_NUMBER;
hash = (53 * hash) + getPath().hashCode();
hash = (37 * hash) + PRODUCER_ID_FIELD_NUMBER;
hash = (53 * hash) + getProducerId().hashCode();
if (!internalGetWriteSessionMeta().getMap().isEmpty()) {
hash = (37 * hash) + WRITE_SESSION_META_FIELD_NUMBER;
hash = (53 * hash) + internalGetWriteSessionMeta().hashCode();
}
hash = (37 * hash) + GET_LAST_SEQ_NO_FIELD_NUMBER;
hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(
getGetLastSeqNo());
switch (partitioningCase_) {
case 4:
hash = (37 * hash) + MESSAGE_GROUP_ID_FIELD_NUMBER;
hash = (53 * hash) + getMessageGroupId().hashCode();
break;
case 5:
hash = (37 * hash) + PARTITION_ID_FIELD_NUMBER;
hash = (53 * hash) + com.google.protobuf.Internal.hashLong(
getPartitionId());
break;
case 7:
hash = (37 * hash) + PARTITION_WITH_GENERATION_FIELD_NUMBER;
hash = (53 * hash) + getPartitionWithGeneration().hashCode();
break;
case 0:
default:
}
hash = (29 * hash) + getUnknownFields().hashCode();
memoizedHashCode = hash;
return hash;
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitRequest parseFrom(
java.nio.ByteBuffer data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitRequest parseFrom(
java.nio.ByteBuffer data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitRequest parseFrom(
com.google.protobuf.ByteString data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitRequest parseFrom(
com.google.protobuf.ByteString data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitRequest parseFrom(byte[] data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitRequest parseFrom(
byte[] data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitRequest parseFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitRequest parseFrom(
java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitRequest parseDelimitedFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input);
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitRequest parseDelimitedFrom(
java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitRequest parseFrom(
com.google.protobuf.CodedInputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitRequest parseFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry);
}
@java.lang.Override
public Builder newBuilderForType() { return newBuilder(); }
public static Builder newBuilder() {
return DEFAULT_INSTANCE.toBuilder();
}
public static Builder newBuilder(tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitRequest prototype) {
return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
}
@java.lang.Override
public Builder toBuilder() {
return this == DEFAULT_INSTANCE
? new Builder() : new Builder().mergeFrom(this);
}
@java.lang.Override
protected Builder newBuilderForType(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
Builder builder = new Builder(parent);
return builder;
}
/**
*
* Handshake request that must be sent to server first.
*
*
* Protobuf type {@code Ydb.Topic.StreamWriteMessage.InitRequest}
*/
public static final class Builder extends
com.google.protobuf.GeneratedMessageV3.Builder implements
// @@protoc_insertion_point(builder_implements:Ydb.Topic.StreamWriteMessage.InitRequest)
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitRequestOrBuilder {
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_StreamWriteMessage_InitRequest_descriptor;
}
@SuppressWarnings({"rawtypes"})
protected com.google.protobuf.MapField internalGetMapField(
int number) {
switch (number) {
case 3:
return internalGetWriteSessionMeta();
default:
throw new RuntimeException(
"Invalid map field number: " + number);
}
}
@SuppressWarnings({"rawtypes"})
protected com.google.protobuf.MapField internalGetMutableMapField(
int number) {
switch (number) {
case 3:
return internalGetMutableWriteSessionMeta();
default:
throw new RuntimeException(
"Invalid map field number: " + number);
}
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_StreamWriteMessage_InitRequest_fieldAccessorTable
.ensureFieldAccessorsInitialized(
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitRequest.class, tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitRequest.Builder.class);
}
// Construct using tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitRequest.newBuilder()
private Builder() {
}
private Builder(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
super(parent);
}
@java.lang.Override
public Builder clear() {
super.clear();
bitField0_ = 0;
path_ = "";
producerId_ = "";
internalGetMutableWriteSessionMeta().clear();
if (partitionWithGenerationBuilder_ != null) {
partitionWithGenerationBuilder_.clear();
}
getLastSeqNo_ = false;
partitioningCase_ = 0;
partitioning_ = null;
return this;
}
@java.lang.Override
public com.google.protobuf.Descriptors.Descriptor
getDescriptorForType() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_StreamWriteMessage_InitRequest_descriptor;
}
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitRequest getDefaultInstanceForType() {
return tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitRequest.getDefaultInstance();
}
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitRequest build() {
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitRequest result = buildPartial();
if (!result.isInitialized()) {
throw newUninitializedMessageException(result);
}
return result;
}
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitRequest buildPartial() {
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitRequest result = new tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitRequest(this);
if (bitField0_ != 0) { buildPartial0(result); }
buildPartialOneofs(result);
onBuilt();
return result;
}
private void buildPartial0(tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitRequest result) {
int from_bitField0_ = bitField0_;
if (((from_bitField0_ & 0x00000001) != 0)) {
result.path_ = path_;
}
if (((from_bitField0_ & 0x00000002) != 0)) {
result.producerId_ = producerId_;
}
if (((from_bitField0_ & 0x00000004) != 0)) {
result.writeSessionMeta_ = internalGetWriteSessionMeta();
result.writeSessionMeta_.makeImmutable();
}
if (((from_bitField0_ & 0x00000040) != 0)) {
result.getLastSeqNo_ = getLastSeqNo_;
}
}
private void buildPartialOneofs(tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitRequest result) {
result.partitioningCase_ = partitioningCase_;
result.partitioning_ = this.partitioning_;
if (partitioningCase_ == 7 &&
partitionWithGenerationBuilder_ != null) {
result.partitioning_ = partitionWithGenerationBuilder_.build();
}
}
@java.lang.Override
public Builder clone() {
return super.clone();
}
@java.lang.Override
public Builder setField(
com.google.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) {
return super.setField(field, value);
}
@java.lang.Override
public Builder clearField(
com.google.protobuf.Descriptors.FieldDescriptor field) {
return super.clearField(field);
}
@java.lang.Override
public Builder clearOneof(
com.google.protobuf.Descriptors.OneofDescriptor oneof) {
return super.clearOneof(oneof);
}
@java.lang.Override
public Builder setRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
int index, java.lang.Object value) {
return super.setRepeatedField(field, index, value);
}
@java.lang.Override
public Builder addRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) {
return super.addRepeatedField(field, value);
}
@java.lang.Override
public Builder mergeFrom(com.google.protobuf.Message other) {
if (other instanceof tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitRequest) {
return mergeFrom((tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitRequest)other);
} else {
super.mergeFrom(other);
return this;
}
}
public Builder mergeFrom(tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitRequest other) {
if (other == tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitRequest.getDefaultInstance()) return this;
if (!other.getPath().isEmpty()) {
path_ = other.path_;
bitField0_ |= 0x00000001;
onChanged();
}
if (!other.getProducerId().isEmpty()) {
producerId_ = other.producerId_;
bitField0_ |= 0x00000002;
onChanged();
}
internalGetMutableWriteSessionMeta().mergeFrom(
other.internalGetWriteSessionMeta());
bitField0_ |= 0x00000004;
if (other.getGetLastSeqNo() != false) {
setGetLastSeqNo(other.getGetLastSeqNo());
}
switch (other.getPartitioningCase()) {
case MESSAGE_GROUP_ID: {
partitioningCase_ = 4;
partitioning_ = other.partitioning_;
onChanged();
break;
}
case PARTITION_ID: {
setPartitionId(other.getPartitionId());
break;
}
case PARTITION_WITH_GENERATION: {
mergePartitionWithGeneration(other.getPartitionWithGeneration());
break;
}
case PARTITIONING_NOT_SET: {
break;
}
}
this.mergeUnknownFields(other.getUnknownFields());
onChanged();
return this;
}
@java.lang.Override
public final boolean isInitialized() {
return true;
}
@java.lang.Override
public Builder mergeFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
if (extensionRegistry == null) {
throw new java.lang.NullPointerException();
}
try {
boolean done = false;
while (!done) {
int tag = input.readTag();
switch (tag) {
case 0:
done = true;
break;
case 10: {
path_ = input.readStringRequireUtf8();
bitField0_ |= 0x00000001;
break;
} // case 10
case 18: {
producerId_ = input.readStringRequireUtf8();
bitField0_ |= 0x00000002;
break;
} // case 18
case 26: {
com.google.protobuf.MapEntry
writeSessionMeta__ = input.readMessage(
WriteSessionMetaDefaultEntryHolder.defaultEntry.getParserForType(), extensionRegistry);
internalGetMutableWriteSessionMeta().getMutableMap().put(
writeSessionMeta__.getKey(), writeSessionMeta__.getValue());
bitField0_ |= 0x00000004;
break;
} // case 26
case 34: {
java.lang.String s = input.readStringRequireUtf8();
partitioningCase_ = 4;
partitioning_ = s;
break;
} // case 34
case 40: {
partitioning_ = input.readInt64();
partitioningCase_ = 5;
break;
} // case 40
case 48: {
getLastSeqNo_ = input.readBool();
bitField0_ |= 0x00000040;
break;
} // case 48
case 58: {
input.readMessage(
getPartitionWithGenerationFieldBuilder().getBuilder(),
extensionRegistry);
partitioningCase_ = 7;
break;
} // case 58
default: {
if (!super.parseUnknownField(input, extensionRegistry, tag)) {
done = true; // was an endgroup tag
}
break;
} // default:
} // switch (tag)
} // while (!done)
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.unwrapIOException();
} finally {
onChanged();
} // finally
return this;
}
private int partitioningCase_ = 0;
private java.lang.Object partitioning_;
public PartitioningCase
getPartitioningCase() {
return PartitioningCase.forNumber(
partitioningCase_);
}
public Builder clearPartitioning() {
partitioningCase_ = 0;
partitioning_ = null;
onChanged();
return this;
}
private int bitField0_;
private java.lang.Object path_ = "";
/**
*
* Full path of topic to write to.
*
*
* string path = 1;
* @return The path.
*/
public java.lang.String getPath() {
java.lang.Object ref = path_;
if (!(ref instanceof java.lang.String)) {
com.google.protobuf.ByteString bs =
(com.google.protobuf.ByteString) ref;
java.lang.String s = bs.toStringUtf8();
path_ = s;
return s;
} else {
return (java.lang.String) ref;
}
}
/**
*
* Full path of topic to write to.
*
*
* string path = 1;
* @return The bytes for path.
*/
public com.google.protobuf.ByteString
getPathBytes() {
java.lang.Object ref = path_;
if (ref instanceof String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
path_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
/**
*
* Full path of topic to write to.
*
*
* string path = 1;
* @param value The path to set.
* @return This builder for chaining.
*/
public Builder setPath(
java.lang.String value) {
if (value == null) { throw new NullPointerException(); }
path_ = value;
bitField0_ |= 0x00000001;
onChanged();
return this;
}
/**
*
* Full path of topic to write to.
*
*
* string path = 1;
* @return This builder for chaining.
*/
public Builder clearPath() {
path_ = getDefaultInstance().getPath();
bitField0_ = (bitField0_ & ~0x00000001);
onChanged();
return this;
}
/**
*
* Full path of topic to write to.
*
*
* string path = 1;
* @param value The bytes for path to set.
* @return This builder for chaining.
*/
public Builder setPathBytes(
com.google.protobuf.ByteString value) {
if (value == null) { throw new NullPointerException(); }
checkByteStringIsUtf8(value);
path_ = value;
bitField0_ |= 0x00000001;
onChanged();
return this;
}
private java.lang.Object producerId_ = "";
/**
*
* Producer identifier of client data stream.
* Used for message deduplication by sequence numbers.
*
*
* string producer_id = 2 [(.Ydb.length) = { ... }
* @return The producerId.
*/
public java.lang.String getProducerId() {
java.lang.Object ref = producerId_;
if (!(ref instanceof java.lang.String)) {
com.google.protobuf.ByteString bs =
(com.google.protobuf.ByteString) ref;
java.lang.String s = bs.toStringUtf8();
producerId_ = s;
return s;
} else {
return (java.lang.String) ref;
}
}
/**
*
* Producer identifier of client data stream.
* Used for message deduplication by sequence numbers.
*
*
* string producer_id = 2 [(.Ydb.length) = { ... }
* @return The bytes for producerId.
*/
public com.google.protobuf.ByteString
getProducerIdBytes() {
java.lang.Object ref = producerId_;
if (ref instanceof String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
producerId_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
/**
*
* Producer identifier of client data stream.
* Used for message deduplication by sequence numbers.
*
*
* string producer_id = 2 [(.Ydb.length) = { ... }
* @param value The producerId to set.
* @return This builder for chaining.
*/
public Builder setProducerId(
java.lang.String value) {
if (value == null) { throw new NullPointerException(); }
producerId_ = value;
bitField0_ |= 0x00000002;
onChanged();
return this;
}
/**
*
* Producer identifier of client data stream.
* Used for message deduplication by sequence numbers.
*
*
* string producer_id = 2 [(.Ydb.length) = { ... }
* @return This builder for chaining.
*/
public Builder clearProducerId() {
producerId_ = getDefaultInstance().getProducerId();
bitField0_ = (bitField0_ & ~0x00000002);
onChanged();
return this;
}
/**
*
* Producer identifier of client data stream.
* Used for message deduplication by sequence numbers.
*
*
* string producer_id = 2 [(.Ydb.length) = { ... }
* @param value The bytes for producerId to set.
* @return This builder for chaining.
*/
public Builder setProducerIdBytes(
com.google.protobuf.ByteString value) {
if (value == null) { throw new NullPointerException(); }
checkByteStringIsUtf8(value);
producerId_ = value;
bitField0_ |= 0x00000002;
onChanged();
return this;
}
private com.google.protobuf.MapField<
java.lang.String, java.lang.String> writeSessionMeta_;
private com.google.protobuf.MapField
internalGetWriteSessionMeta() {
if (writeSessionMeta_ == null) {
return com.google.protobuf.MapField.emptyMapField(
WriteSessionMetaDefaultEntryHolder.defaultEntry);
}
return writeSessionMeta_;
}
private com.google.protobuf.MapField
internalGetMutableWriteSessionMeta() {
if (writeSessionMeta_ == null) {
writeSessionMeta_ = com.google.protobuf.MapField.newMapField(
WriteSessionMetaDefaultEntryHolder.defaultEntry);
}
if (!writeSessionMeta_.isMutable()) {
writeSessionMeta_ = writeSessionMeta_.copy();
}
bitField0_ |= 0x00000004;
onChanged();
return writeSessionMeta_;
}
public int getWriteSessionMetaCount() {
return internalGetWriteSessionMeta().getMap().size();
}
/**
*
* User metadata attached to this write session.
* Reader will get this session meta data with each message read.
*
*
* map<string, string> write_session_meta = 3;
*/
@java.lang.Override
public boolean containsWriteSessionMeta(
java.lang.String key) {
if (key == null) { throw new NullPointerException("map key"); }
return internalGetWriteSessionMeta().getMap().containsKey(key);
}
/**
* Use {@link #getWriteSessionMetaMap()} instead.
*/
@java.lang.Override
@java.lang.Deprecated
public java.util.Map getWriteSessionMeta() {
return getWriteSessionMetaMap();
}
/**
*
* User metadata attached to this write session.
* Reader will get this session meta data with each message read.
*
*
* map<string, string> write_session_meta = 3;
*/
@java.lang.Override
public java.util.Map getWriteSessionMetaMap() {
return internalGetWriteSessionMeta().getMap();
}
/**
*
* User metadata attached to this write session.
* Reader will get this session meta data with each message read.
*
*
* map<string, string> write_session_meta = 3;
*/
@java.lang.Override
public /* nullable */
java.lang.String getWriteSessionMetaOrDefault(
java.lang.String key,
/* nullable */
java.lang.String defaultValue) {
if (key == null) { throw new NullPointerException("map key"); }
java.util.Map map =
internalGetWriteSessionMeta().getMap();
return map.containsKey(key) ? map.get(key) : defaultValue;
}
/**
*
* User metadata attached to this write session.
* Reader will get this session meta data with each message read.
*
*
* map<string, string> write_session_meta = 3;
*/
@java.lang.Override
public java.lang.String getWriteSessionMetaOrThrow(
java.lang.String key) {
if (key == null) { throw new NullPointerException("map key"); }
java.util.Map map =
internalGetWriteSessionMeta().getMap();
if (!map.containsKey(key)) {
throw new java.lang.IllegalArgumentException();
}
return map.get(key);
}
public Builder clearWriteSessionMeta() {
bitField0_ = (bitField0_ & ~0x00000004);
internalGetMutableWriteSessionMeta().getMutableMap()
.clear();
return this;
}
/**
*
* User metadata attached to this write session.
* Reader will get this session meta data with each message read.
*
*
* map<string, string> write_session_meta = 3;
*/
public Builder removeWriteSessionMeta(
java.lang.String key) {
if (key == null) { throw new NullPointerException("map key"); }
internalGetMutableWriteSessionMeta().getMutableMap()
.remove(key);
return this;
}
/**
* Use alternate mutation accessors instead.
*/
@java.lang.Deprecated
public java.util.Map
getMutableWriteSessionMeta() {
bitField0_ |= 0x00000004;
return internalGetMutableWriteSessionMeta().getMutableMap();
}
/**
*
* User metadata attached to this write session.
* Reader will get this session meta data with each message read.
*
*
* map<string, string> write_session_meta = 3;
*/
public Builder putWriteSessionMeta(
java.lang.String key,
java.lang.String value) {
if (key == null) { throw new NullPointerException("map key"); }
if (value == null) { throw new NullPointerException("map value"); }
internalGetMutableWriteSessionMeta().getMutableMap()
.put(key, value);
bitField0_ |= 0x00000004;
return this;
}
/**
*
* User metadata attached to this write session.
* Reader will get this session meta data with each message read.
*
*
* map<string, string> write_session_meta = 3;
*/
public Builder putAllWriteSessionMeta(
java.util.Map values) {
internalGetMutableWriteSessionMeta().getMutableMap()
.putAll(values);
bitField0_ |= 0x00000004;
return this;
}
/**
*
* All messages with given pair (producer_id, message_group_id) go to single partition in order of writes.
*
*
* string message_group_id = 4 [(.Ydb.length) = { ... }
* @return Whether the messageGroupId field is set.
*/
@java.lang.Override
public boolean hasMessageGroupId() {
return partitioningCase_ == 4;
}
/**
*
* All messages with given pair (producer_id, message_group_id) go to single partition in order of writes.
*
*
* string message_group_id = 4 [(.Ydb.length) = { ... }
* @return The messageGroupId.
*/
@java.lang.Override
public java.lang.String getMessageGroupId() {
java.lang.Object ref = "";
if (partitioningCase_ == 4) {
ref = partitioning_;
}
if (!(ref instanceof java.lang.String)) {
com.google.protobuf.ByteString bs =
(com.google.protobuf.ByteString) ref;
java.lang.String s = bs.toStringUtf8();
if (partitioningCase_ == 4) {
partitioning_ = s;
}
return s;
} else {
return (java.lang.String) ref;
}
}
/**
*
* All messages with given pair (producer_id, message_group_id) go to single partition in order of writes.
*
*
* string message_group_id = 4 [(.Ydb.length) = { ... }
* @return The bytes for messageGroupId.
*/
@java.lang.Override
public com.google.protobuf.ByteString
getMessageGroupIdBytes() {
java.lang.Object ref = "";
if (partitioningCase_ == 4) {
ref = partitioning_;
}
if (ref instanceof String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
if (partitioningCase_ == 4) {
partitioning_ = b;
}
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
/**
*
* All messages with given pair (producer_id, message_group_id) go to single partition in order of writes.
*
*
* string message_group_id = 4 [(.Ydb.length) = { ... }
* @param value The messageGroupId to set.
* @return This builder for chaining.
*/
public Builder setMessageGroupId(
java.lang.String value) {
if (value == null) { throw new NullPointerException(); }
partitioningCase_ = 4;
partitioning_ = value;
onChanged();
return this;
}
/**
*
* All messages with given pair (producer_id, message_group_id) go to single partition in order of writes.
*
*
* string message_group_id = 4 [(.Ydb.length) = { ... }
* @return This builder for chaining.
*/
public Builder clearMessageGroupId() {
if (partitioningCase_ == 4) {
partitioningCase_ = 0;
partitioning_ = null;
onChanged();
}
return this;
}
/**
*
* All messages with given pair (producer_id, message_group_id) go to single partition in order of writes.
*
*
* string message_group_id = 4 [(.Ydb.length) = { ... }
* @param value The bytes for messageGroupId to set.
* @return This builder for chaining.
*/
public Builder setMessageGroupIdBytes(
com.google.protobuf.ByteString value) {
if (value == null) { throw new NullPointerException(); }
checkByteStringIsUtf8(value);
partitioningCase_ = 4;
partitioning_ = value;
onChanged();
return this;
}
/**
*
* Explicit partition id to write to.
*
*
* int64 partition_id = 5;
* @return Whether the partitionId field is set.
*/
public boolean hasPartitionId() {
return partitioningCase_ == 5;
}
/**
*
* Explicit partition id to write to.
*
*
* int64 partition_id = 5;
* @return The partitionId.
*/
public long getPartitionId() {
if (partitioningCase_ == 5) {
return (java.lang.Long) partitioning_;
}
return 0L;
}
/**
*
* Explicit partition id to write to.
*
*
* int64 partition_id = 5;
* @param value The partitionId to set.
* @return This builder for chaining.
*/
public Builder setPartitionId(long value) {
partitioningCase_ = 5;
partitioning_ = value;
onChanged();
return this;
}
/**
*
* Explicit partition id to write to.
*
*
* int64 partition_id = 5;
* @return This builder for chaining.
*/
public Builder clearPartitionId() {
if (partitioningCase_ == 5) {
partitioningCase_ = 0;
partitioning_ = null;
onChanged();
}
return this;
}
private com.google.protobuf.SingleFieldBuilderV3<
tech.ydb.proto.topic.YdbTopic.PartitionWithGeneration, tech.ydb.proto.topic.YdbTopic.PartitionWithGeneration.Builder, tech.ydb.proto.topic.YdbTopic.PartitionWithGenerationOrBuilder> partitionWithGenerationBuilder_;
/**
*
* Explicit partition location to write to.
*
*
* .Ydb.Topic.PartitionWithGeneration partition_with_generation = 7;
* @return Whether the partitionWithGeneration field is set.
*/
@java.lang.Override
public boolean hasPartitionWithGeneration() {
return partitioningCase_ == 7;
}
/**
*
* Explicit partition location to write to.
*
*
* .Ydb.Topic.PartitionWithGeneration partition_with_generation = 7;
* @return The partitionWithGeneration.
*/
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.PartitionWithGeneration getPartitionWithGeneration() {
if (partitionWithGenerationBuilder_ == null) {
if (partitioningCase_ == 7) {
return (tech.ydb.proto.topic.YdbTopic.PartitionWithGeneration) partitioning_;
}
return tech.ydb.proto.topic.YdbTopic.PartitionWithGeneration.getDefaultInstance();
} else {
if (partitioningCase_ == 7) {
return partitionWithGenerationBuilder_.getMessage();
}
return tech.ydb.proto.topic.YdbTopic.PartitionWithGeneration.getDefaultInstance();
}
}
/**
*
* Explicit partition location to write to.
*
*
* .Ydb.Topic.PartitionWithGeneration partition_with_generation = 7;
*/
public Builder setPartitionWithGeneration(tech.ydb.proto.topic.YdbTopic.PartitionWithGeneration value) {
if (partitionWithGenerationBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
partitioning_ = value;
onChanged();
} else {
partitionWithGenerationBuilder_.setMessage(value);
}
partitioningCase_ = 7;
return this;
}
/**
*
* Explicit partition location to write to.
*
*
* .Ydb.Topic.PartitionWithGeneration partition_with_generation = 7;
*/
public Builder setPartitionWithGeneration(
tech.ydb.proto.topic.YdbTopic.PartitionWithGeneration.Builder builderForValue) {
if (partitionWithGenerationBuilder_ == null) {
partitioning_ = builderForValue.build();
onChanged();
} else {
partitionWithGenerationBuilder_.setMessage(builderForValue.build());
}
partitioningCase_ = 7;
return this;
}
/**
*
* Explicit partition location to write to.
*
*
* .Ydb.Topic.PartitionWithGeneration partition_with_generation = 7;
*/
public Builder mergePartitionWithGeneration(tech.ydb.proto.topic.YdbTopic.PartitionWithGeneration value) {
if (partitionWithGenerationBuilder_ == null) {
if (partitioningCase_ == 7 &&
partitioning_ != tech.ydb.proto.topic.YdbTopic.PartitionWithGeneration.getDefaultInstance()) {
partitioning_ = tech.ydb.proto.topic.YdbTopic.PartitionWithGeneration.newBuilder((tech.ydb.proto.topic.YdbTopic.PartitionWithGeneration) partitioning_)
.mergeFrom(value).buildPartial();
} else {
partitioning_ = value;
}
onChanged();
} else {
if (partitioningCase_ == 7) {
partitionWithGenerationBuilder_.mergeFrom(value);
} else {
partitionWithGenerationBuilder_.setMessage(value);
}
}
partitioningCase_ = 7;
return this;
}
/**
*
* Explicit partition location to write to.
*
*
* .Ydb.Topic.PartitionWithGeneration partition_with_generation = 7;
*/
public Builder clearPartitionWithGeneration() {
if (partitionWithGenerationBuilder_ == null) {
if (partitioningCase_ == 7) {
partitioningCase_ = 0;
partitioning_ = null;
onChanged();
}
} else {
if (partitioningCase_ == 7) {
partitioningCase_ = 0;
partitioning_ = null;
}
partitionWithGenerationBuilder_.clear();
}
return this;
}
/**
*
* Explicit partition location to write to.
*
*
* .Ydb.Topic.PartitionWithGeneration partition_with_generation = 7;
*/
public tech.ydb.proto.topic.YdbTopic.PartitionWithGeneration.Builder getPartitionWithGenerationBuilder() {
return getPartitionWithGenerationFieldBuilder().getBuilder();
}
/**
*
* Explicit partition location to write to.
*
*
* .Ydb.Topic.PartitionWithGeneration partition_with_generation = 7;
*/
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.PartitionWithGenerationOrBuilder getPartitionWithGenerationOrBuilder() {
if ((partitioningCase_ == 7) && (partitionWithGenerationBuilder_ != null)) {
return partitionWithGenerationBuilder_.getMessageOrBuilder();
} else {
if (partitioningCase_ == 7) {
return (tech.ydb.proto.topic.YdbTopic.PartitionWithGeneration) partitioning_;
}
return tech.ydb.proto.topic.YdbTopic.PartitionWithGeneration.getDefaultInstance();
}
}
/**
*
* Explicit partition location to write to.
*
*
* .Ydb.Topic.PartitionWithGeneration partition_with_generation = 7;
*/
private com.google.protobuf.SingleFieldBuilderV3<
tech.ydb.proto.topic.YdbTopic.PartitionWithGeneration, tech.ydb.proto.topic.YdbTopic.PartitionWithGeneration.Builder, tech.ydb.proto.topic.YdbTopic.PartitionWithGenerationOrBuilder>
getPartitionWithGenerationFieldBuilder() {
if (partitionWithGenerationBuilder_ == null) {
if (!(partitioningCase_ == 7)) {
partitioning_ = tech.ydb.proto.topic.YdbTopic.PartitionWithGeneration.getDefaultInstance();
}
partitionWithGenerationBuilder_ = new com.google.protobuf.SingleFieldBuilderV3<
tech.ydb.proto.topic.YdbTopic.PartitionWithGeneration, tech.ydb.proto.topic.YdbTopic.PartitionWithGeneration.Builder, tech.ydb.proto.topic.YdbTopic.PartitionWithGenerationOrBuilder>(
(tech.ydb.proto.topic.YdbTopic.PartitionWithGeneration) partitioning_,
getParentForChildren(),
isClean());
partitioning_ = null;
}
partitioningCase_ = 7;
onChanged();
return partitionWithGenerationBuilder_;
}
private boolean getLastSeqNo_ ;
/**
*
* Explicitly request for last sequential number
* It may be expensive, if producer wrote to many partitions before.
*
*
* bool get_last_seq_no = 6;
* @return The getLastSeqNo.
*/
@java.lang.Override
public boolean getGetLastSeqNo() {
return getLastSeqNo_;
}
/**
*
* Explicitly request for last sequential number
* It may be expensive, if producer wrote to many partitions before.
*
*
* bool get_last_seq_no = 6;
* @param value The getLastSeqNo to set.
* @return This builder for chaining.
*/
public Builder setGetLastSeqNo(boolean value) {
getLastSeqNo_ = value;
bitField0_ |= 0x00000040;
onChanged();
return this;
}
/**
*
* Explicitly request for last sequential number
* It may be expensive, if producer wrote to many partitions before.
*
*
* bool get_last_seq_no = 6;
* @return This builder for chaining.
*/
public Builder clearGetLastSeqNo() {
bitField0_ = (bitField0_ & ~0x00000040);
getLastSeqNo_ = false;
onChanged();
return this;
}
@java.lang.Override
public final Builder setUnknownFields(
final com.google.protobuf.UnknownFieldSet unknownFields) {
return super.setUnknownFields(unknownFields);
}
@java.lang.Override
public final Builder mergeUnknownFields(
final com.google.protobuf.UnknownFieldSet unknownFields) {
return super.mergeUnknownFields(unknownFields);
}
// @@protoc_insertion_point(builder_scope:Ydb.Topic.StreamWriteMessage.InitRequest)
}
// @@protoc_insertion_point(class_scope:Ydb.Topic.StreamWriteMessage.InitRequest)
private static final tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitRequest DEFAULT_INSTANCE;
static {
DEFAULT_INSTANCE = new tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitRequest();
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitRequest getDefaultInstance() {
return DEFAULT_INSTANCE;
}
private static final com.google.protobuf.Parser
PARSER = new com.google.protobuf.AbstractParser() {
@java.lang.Override
public InitRequest parsePartialFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
Builder builder = newBuilder();
try {
builder.mergeFrom(input, extensionRegistry);
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.setUnfinishedMessage(builder.buildPartial());
} catch (com.google.protobuf.UninitializedMessageException e) {
throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial());
} catch (java.io.IOException e) {
throw new com.google.protobuf.InvalidProtocolBufferException(e)
.setUnfinishedMessage(builder.buildPartial());
}
return builder.buildPartial();
}
};
public static com.google.protobuf.Parser parser() {
return PARSER;
}
@java.lang.Override
public com.google.protobuf.Parser getParserForType() {
return PARSER;
}
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitRequest getDefaultInstanceForType() {
return DEFAULT_INSTANCE;
}
}
public interface InitResponseOrBuilder extends
// @@protoc_insertion_point(interface_extends:Ydb.Topic.StreamWriteMessage.InitResponse)
com.google.protobuf.MessageOrBuilder {
/**
*
* Last persisted message's sequence number for this producer.
* Zero for new producer.
*
*
* int64 last_seq_no = 1;
* @return The lastSeqNo.
*/
long getLastSeqNo();
/**
*
* Unique identifier of write session. Used for debug purposes.
*
*
* string session_id = 2;
* @return The sessionId.
*/
java.lang.String getSessionId();
/**
*
* Unique identifier of write session. Used for debug purposes.
*
*
* string session_id = 2;
* @return The bytes for sessionId.
*/
com.google.protobuf.ByteString
getSessionIdBytes();
/**
*
* Identifier of partition that is matched for this write session.
*
*
* int64 partition_id = 3;
* @return The partitionId.
*/
long getPartitionId();
/**
*
* Client can only use compression codecs from this set to write messages to topic.
* Otherwise session will be closed with BAD_REQUEST.
*
*
* .Ydb.Topic.SupportedCodecs supported_codecs = 4;
* @return Whether the supportedCodecs field is set.
*/
boolean hasSupportedCodecs();
/**
*
* Client can only use compression codecs from this set to write messages to topic.
* Otherwise session will be closed with BAD_REQUEST.
*
*
* .Ydb.Topic.SupportedCodecs supported_codecs = 4;
* @return The supportedCodecs.
*/
tech.ydb.proto.topic.YdbTopic.SupportedCodecs getSupportedCodecs();
/**
*
* Client can only use compression codecs from this set to write messages to topic.
* Otherwise session will be closed with BAD_REQUEST.
*
*
* .Ydb.Topic.SupportedCodecs supported_codecs = 4;
*/
tech.ydb.proto.topic.YdbTopic.SupportedCodecsOrBuilder getSupportedCodecsOrBuilder();
}
/**
*
* Response to the handshake.
*
*
* Protobuf type {@code Ydb.Topic.StreamWriteMessage.InitResponse}
*/
public static final class InitResponse extends
com.google.protobuf.GeneratedMessageV3 implements
// @@protoc_insertion_point(message_implements:Ydb.Topic.StreamWriteMessage.InitResponse)
InitResponseOrBuilder {
private static final long serialVersionUID = 0L;
// Use InitResponse.newBuilder() to construct.
private InitResponse(com.google.protobuf.GeneratedMessageV3.Builder> builder) {
super(builder);
}
private InitResponse() {
sessionId_ = "";
}
@java.lang.Override
@SuppressWarnings({"unused"})
protected java.lang.Object newInstance(
UnusedPrivateParameter unused) {
return new InitResponse();
}
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_StreamWriteMessage_InitResponse_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_StreamWriteMessage_InitResponse_fieldAccessorTable
.ensureFieldAccessorsInitialized(
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitResponse.class, tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitResponse.Builder.class);
}
private int bitField0_;
public static final int LAST_SEQ_NO_FIELD_NUMBER = 1;
private long lastSeqNo_ = 0L;
/**
*
* Last persisted message's sequence number for this producer.
* Zero for new producer.
*
*
* int64 last_seq_no = 1;
* @return The lastSeqNo.
*/
@java.lang.Override
public long getLastSeqNo() {
return lastSeqNo_;
}
public static final int SESSION_ID_FIELD_NUMBER = 2;
@SuppressWarnings("serial")
private volatile java.lang.Object sessionId_ = "";
/**
*
* Unique identifier of write session. Used for debug purposes.
*
*
* string session_id = 2;
* @return The sessionId.
*/
@java.lang.Override
public java.lang.String getSessionId() {
java.lang.Object ref = sessionId_;
if (ref instanceof java.lang.String) {
return (java.lang.String) ref;
} else {
com.google.protobuf.ByteString bs =
(com.google.protobuf.ByteString) ref;
java.lang.String s = bs.toStringUtf8();
sessionId_ = s;
return s;
}
}
/**
*
* Unique identifier of write session. Used for debug purposes.
*
*
* string session_id = 2;
* @return The bytes for sessionId.
*/
@java.lang.Override
public com.google.protobuf.ByteString
getSessionIdBytes() {
java.lang.Object ref = sessionId_;
if (ref instanceof java.lang.String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
sessionId_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
public static final int PARTITION_ID_FIELD_NUMBER = 3;
private long partitionId_ = 0L;
/**
*
* Identifier of partition that is matched for this write session.
*
*
* int64 partition_id = 3;
* @return The partitionId.
*/
@java.lang.Override
public long getPartitionId() {
return partitionId_;
}
public static final int SUPPORTED_CODECS_FIELD_NUMBER = 4;
private tech.ydb.proto.topic.YdbTopic.SupportedCodecs supportedCodecs_;
/**
*
* Client can only use compression codecs from this set to write messages to topic.
* Otherwise session will be closed with BAD_REQUEST.
*
*
* .Ydb.Topic.SupportedCodecs supported_codecs = 4;
* @return Whether the supportedCodecs field is set.
*/
@java.lang.Override
public boolean hasSupportedCodecs() {
return ((bitField0_ & 0x00000001) != 0);
}
/**
*
* Client can only use compression codecs from this set to write messages to topic.
* Otherwise session will be closed with BAD_REQUEST.
*
*
* .Ydb.Topic.SupportedCodecs supported_codecs = 4;
* @return The supportedCodecs.
*/
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.SupportedCodecs getSupportedCodecs() {
return supportedCodecs_ == null ? tech.ydb.proto.topic.YdbTopic.SupportedCodecs.getDefaultInstance() : supportedCodecs_;
}
/**
*
* Client can only use compression codecs from this set to write messages to topic.
* Otherwise session will be closed with BAD_REQUEST.
*
*
* .Ydb.Topic.SupportedCodecs supported_codecs = 4;
*/
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.SupportedCodecsOrBuilder getSupportedCodecsOrBuilder() {
return supportedCodecs_ == null ? tech.ydb.proto.topic.YdbTopic.SupportedCodecs.getDefaultInstance() : supportedCodecs_;
}
private byte memoizedIsInitialized = -1;
@java.lang.Override
public final boolean isInitialized() {
byte isInitialized = memoizedIsInitialized;
if (isInitialized == 1) return true;
if (isInitialized == 0) return false;
memoizedIsInitialized = 1;
return true;
}
@java.lang.Override
public void writeTo(com.google.protobuf.CodedOutputStream output)
throws java.io.IOException {
if (lastSeqNo_ != 0L) {
output.writeInt64(1, lastSeqNo_);
}
if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(sessionId_)) {
com.google.protobuf.GeneratedMessageV3.writeString(output, 2, sessionId_);
}
if (partitionId_ != 0L) {
output.writeInt64(3, partitionId_);
}
if (((bitField0_ & 0x00000001) != 0)) {
output.writeMessage(4, getSupportedCodecs());
}
getUnknownFields().writeTo(output);
}
@java.lang.Override
public int getSerializedSize() {
int size = memoizedSize;
if (size != -1) return size;
size = 0;
if (lastSeqNo_ != 0L) {
size += com.google.protobuf.CodedOutputStream
.computeInt64Size(1, lastSeqNo_);
}
if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(sessionId_)) {
size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, sessionId_);
}
if (partitionId_ != 0L) {
size += com.google.protobuf.CodedOutputStream
.computeInt64Size(3, partitionId_);
}
if (((bitField0_ & 0x00000001) != 0)) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(4, getSupportedCodecs());
}
size += getUnknownFields().getSerializedSize();
memoizedSize = size;
return size;
}
@java.lang.Override
public boolean equals(final java.lang.Object obj) {
if (obj == this) {
return true;
}
if (!(obj instanceof tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitResponse)) {
return super.equals(obj);
}
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitResponse other = (tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitResponse) obj;
if (getLastSeqNo()
!= other.getLastSeqNo()) return false;
if (!getSessionId()
.equals(other.getSessionId())) return false;
if (getPartitionId()
!= other.getPartitionId()) return false;
if (hasSupportedCodecs() != other.hasSupportedCodecs()) return false;
if (hasSupportedCodecs()) {
if (!getSupportedCodecs()
.equals(other.getSupportedCodecs())) return false;
}
if (!getUnknownFields().equals(other.getUnknownFields())) return false;
return true;
}
@java.lang.Override
public int hashCode() {
if (memoizedHashCode != 0) {
return memoizedHashCode;
}
int hash = 41;
hash = (19 * hash) + getDescriptor().hashCode();
hash = (37 * hash) + LAST_SEQ_NO_FIELD_NUMBER;
hash = (53 * hash) + com.google.protobuf.Internal.hashLong(
getLastSeqNo());
hash = (37 * hash) + SESSION_ID_FIELD_NUMBER;
hash = (53 * hash) + getSessionId().hashCode();
hash = (37 * hash) + PARTITION_ID_FIELD_NUMBER;
hash = (53 * hash) + com.google.protobuf.Internal.hashLong(
getPartitionId());
if (hasSupportedCodecs()) {
hash = (37 * hash) + SUPPORTED_CODECS_FIELD_NUMBER;
hash = (53 * hash) + getSupportedCodecs().hashCode();
}
hash = (29 * hash) + getUnknownFields().hashCode();
memoizedHashCode = hash;
return hash;
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitResponse parseFrom(
java.nio.ByteBuffer data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitResponse parseFrom(
java.nio.ByteBuffer data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitResponse parseFrom(
com.google.protobuf.ByteString data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitResponse parseFrom(
com.google.protobuf.ByteString data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitResponse parseFrom(byte[] data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitResponse parseFrom(
byte[] data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitResponse parseFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitResponse parseFrom(
java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitResponse parseDelimitedFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input);
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitResponse parseDelimitedFrom(
java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitResponse parseFrom(
com.google.protobuf.CodedInputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitResponse parseFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry);
}
@java.lang.Override
public Builder newBuilderForType() { return newBuilder(); }
public static Builder newBuilder() {
return DEFAULT_INSTANCE.toBuilder();
}
public static Builder newBuilder(tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitResponse prototype) {
return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
}
@java.lang.Override
public Builder toBuilder() {
return this == DEFAULT_INSTANCE
? new Builder() : new Builder().mergeFrom(this);
}
@java.lang.Override
protected Builder newBuilderForType(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
Builder builder = new Builder(parent);
return builder;
}
/**
*
* Response to the handshake.
*
*
* Protobuf type {@code Ydb.Topic.StreamWriteMessage.InitResponse}
*/
public static final class Builder extends
com.google.protobuf.GeneratedMessageV3.Builder implements
// @@protoc_insertion_point(builder_implements:Ydb.Topic.StreamWriteMessage.InitResponse)
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitResponseOrBuilder {
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_StreamWriteMessage_InitResponse_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_StreamWriteMessage_InitResponse_fieldAccessorTable
.ensureFieldAccessorsInitialized(
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitResponse.class, tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitResponse.Builder.class);
}
// Construct using tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitResponse.newBuilder()
private Builder() {
maybeForceBuilderInitialization();
}
private Builder(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
super(parent);
maybeForceBuilderInitialization();
}
private void maybeForceBuilderInitialization() {
if (com.google.protobuf.GeneratedMessageV3
.alwaysUseFieldBuilders) {
getSupportedCodecsFieldBuilder();
}
}
@java.lang.Override
public Builder clear() {
super.clear();
bitField0_ = 0;
lastSeqNo_ = 0L;
sessionId_ = "";
partitionId_ = 0L;
supportedCodecs_ = null;
if (supportedCodecsBuilder_ != null) {
supportedCodecsBuilder_.dispose();
supportedCodecsBuilder_ = null;
}
return this;
}
@java.lang.Override
public com.google.protobuf.Descriptors.Descriptor
getDescriptorForType() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_StreamWriteMessage_InitResponse_descriptor;
}
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitResponse getDefaultInstanceForType() {
return tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitResponse.getDefaultInstance();
}
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitResponse build() {
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitResponse result = buildPartial();
if (!result.isInitialized()) {
throw newUninitializedMessageException(result);
}
return result;
}
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitResponse buildPartial() {
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitResponse result = new tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitResponse(this);
if (bitField0_ != 0) { buildPartial0(result); }
onBuilt();
return result;
}
private void buildPartial0(tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitResponse result) {
int from_bitField0_ = bitField0_;
if (((from_bitField0_ & 0x00000001) != 0)) {
result.lastSeqNo_ = lastSeqNo_;
}
if (((from_bitField0_ & 0x00000002) != 0)) {
result.sessionId_ = sessionId_;
}
if (((from_bitField0_ & 0x00000004) != 0)) {
result.partitionId_ = partitionId_;
}
int to_bitField0_ = 0;
if (((from_bitField0_ & 0x00000008) != 0)) {
result.supportedCodecs_ = supportedCodecsBuilder_ == null
? supportedCodecs_
: supportedCodecsBuilder_.build();
to_bitField0_ |= 0x00000001;
}
result.bitField0_ |= to_bitField0_;
}
@java.lang.Override
public Builder clone() {
return super.clone();
}
@java.lang.Override
public Builder setField(
com.google.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) {
return super.setField(field, value);
}
@java.lang.Override
public Builder clearField(
com.google.protobuf.Descriptors.FieldDescriptor field) {
return super.clearField(field);
}
@java.lang.Override
public Builder clearOneof(
com.google.protobuf.Descriptors.OneofDescriptor oneof) {
return super.clearOneof(oneof);
}
@java.lang.Override
public Builder setRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
int index, java.lang.Object value) {
return super.setRepeatedField(field, index, value);
}
@java.lang.Override
public Builder addRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) {
return super.addRepeatedField(field, value);
}
@java.lang.Override
public Builder mergeFrom(com.google.protobuf.Message other) {
if (other instanceof tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitResponse) {
return mergeFrom((tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitResponse)other);
} else {
super.mergeFrom(other);
return this;
}
}
public Builder mergeFrom(tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitResponse other) {
if (other == tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitResponse.getDefaultInstance()) return this;
if (other.getLastSeqNo() != 0L) {
setLastSeqNo(other.getLastSeqNo());
}
if (!other.getSessionId().isEmpty()) {
sessionId_ = other.sessionId_;
bitField0_ |= 0x00000002;
onChanged();
}
if (other.getPartitionId() != 0L) {
setPartitionId(other.getPartitionId());
}
if (other.hasSupportedCodecs()) {
mergeSupportedCodecs(other.getSupportedCodecs());
}
this.mergeUnknownFields(other.getUnknownFields());
onChanged();
return this;
}
@java.lang.Override
public final boolean isInitialized() {
return true;
}
@java.lang.Override
public Builder mergeFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
if (extensionRegistry == null) {
throw new java.lang.NullPointerException();
}
try {
boolean done = false;
while (!done) {
int tag = input.readTag();
switch (tag) {
case 0:
done = true;
break;
case 8: {
lastSeqNo_ = input.readInt64();
bitField0_ |= 0x00000001;
break;
} // case 8
case 18: {
sessionId_ = input.readStringRequireUtf8();
bitField0_ |= 0x00000002;
break;
} // case 18
case 24: {
partitionId_ = input.readInt64();
bitField0_ |= 0x00000004;
break;
} // case 24
case 34: {
input.readMessage(
getSupportedCodecsFieldBuilder().getBuilder(),
extensionRegistry);
bitField0_ |= 0x00000008;
break;
} // case 34
default: {
if (!super.parseUnknownField(input, extensionRegistry, tag)) {
done = true; // was an endgroup tag
}
break;
} // default:
} // switch (tag)
} // while (!done)
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.unwrapIOException();
} finally {
onChanged();
} // finally
return this;
}
private int bitField0_;
private long lastSeqNo_ ;
/**
*
* Last persisted message's sequence number for this producer.
* Zero for new producer.
*
*
* int64 last_seq_no = 1;
* @return The lastSeqNo.
*/
@java.lang.Override
public long getLastSeqNo() {
return lastSeqNo_;
}
/**
*
* Last persisted message's sequence number for this producer.
* Zero for new producer.
*
*
* int64 last_seq_no = 1;
* @param value The lastSeqNo to set.
* @return This builder for chaining.
*/
public Builder setLastSeqNo(long value) {
lastSeqNo_ = value;
bitField0_ |= 0x00000001;
onChanged();
return this;
}
/**
*
* Last persisted message's sequence number for this producer.
* Zero for new producer.
*
*
* int64 last_seq_no = 1;
* @return This builder for chaining.
*/
public Builder clearLastSeqNo() {
bitField0_ = (bitField0_ & ~0x00000001);
lastSeqNo_ = 0L;
onChanged();
return this;
}
private java.lang.Object sessionId_ = "";
/**
*
* Unique identifier of write session. Used for debug purposes.
*
*
* string session_id = 2;
* @return The sessionId.
*/
public java.lang.String getSessionId() {
java.lang.Object ref = sessionId_;
if (!(ref instanceof java.lang.String)) {
com.google.protobuf.ByteString bs =
(com.google.protobuf.ByteString) ref;
java.lang.String s = bs.toStringUtf8();
sessionId_ = s;
return s;
} else {
return (java.lang.String) ref;
}
}
/**
*
* Unique identifier of write session. Used for debug purposes.
*
*
* string session_id = 2;
* @return The bytes for sessionId.
*/
public com.google.protobuf.ByteString
getSessionIdBytes() {
java.lang.Object ref = sessionId_;
if (ref instanceof String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
sessionId_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
/**
*
* Unique identifier of write session. Used for debug purposes.
*
*
* string session_id = 2;
* @param value The sessionId to set.
* @return This builder for chaining.
*/
public Builder setSessionId(
java.lang.String value) {
if (value == null) { throw new NullPointerException(); }
sessionId_ = value;
bitField0_ |= 0x00000002;
onChanged();
return this;
}
/**
*
* Unique identifier of write session. Used for debug purposes.
*
*
* string session_id = 2;
* @return This builder for chaining.
*/
public Builder clearSessionId() {
sessionId_ = getDefaultInstance().getSessionId();
bitField0_ = (bitField0_ & ~0x00000002);
onChanged();
return this;
}
/**
*
* Unique identifier of write session. Used for debug purposes.
*
*
* string session_id = 2;
* @param value The bytes for sessionId to set.
* @return This builder for chaining.
*/
public Builder setSessionIdBytes(
com.google.protobuf.ByteString value) {
if (value == null) { throw new NullPointerException(); }
checkByteStringIsUtf8(value);
sessionId_ = value;
bitField0_ |= 0x00000002;
onChanged();
return this;
}
private long partitionId_ ;
/**
*
* Identifier of partition that is matched for this write session.
*
*
* int64 partition_id = 3;
* @return The partitionId.
*/
@java.lang.Override
public long getPartitionId() {
return partitionId_;
}
/**
*
* Identifier of partition that is matched for this write session.
*
*
* int64 partition_id = 3;
* @param value The partitionId to set.
* @return This builder for chaining.
*/
public Builder setPartitionId(long value) {
partitionId_ = value;
bitField0_ |= 0x00000004;
onChanged();
return this;
}
/**
*
* Identifier of partition that is matched for this write session.
*
*
* int64 partition_id = 3;
* @return This builder for chaining.
*/
public Builder clearPartitionId() {
bitField0_ = (bitField0_ & ~0x00000004);
partitionId_ = 0L;
onChanged();
return this;
}
private tech.ydb.proto.topic.YdbTopic.SupportedCodecs supportedCodecs_;
private com.google.protobuf.SingleFieldBuilderV3<
tech.ydb.proto.topic.YdbTopic.SupportedCodecs, tech.ydb.proto.topic.YdbTopic.SupportedCodecs.Builder, tech.ydb.proto.topic.YdbTopic.SupportedCodecsOrBuilder> supportedCodecsBuilder_;
/**
*
* Client can only use compression codecs from this set to write messages to topic.
* Otherwise session will be closed with BAD_REQUEST.
*
*
* .Ydb.Topic.SupportedCodecs supported_codecs = 4;
* @return Whether the supportedCodecs field is set.
*/
public boolean hasSupportedCodecs() {
return ((bitField0_ & 0x00000008) != 0);
}
/**
*
* Client can only use compression codecs from this set to write messages to topic.
* Otherwise session will be closed with BAD_REQUEST.
*
*
* .Ydb.Topic.SupportedCodecs supported_codecs = 4;
* @return The supportedCodecs.
*/
public tech.ydb.proto.topic.YdbTopic.SupportedCodecs getSupportedCodecs() {
if (supportedCodecsBuilder_ == null) {
return supportedCodecs_ == null ? tech.ydb.proto.topic.YdbTopic.SupportedCodecs.getDefaultInstance() : supportedCodecs_;
} else {
return supportedCodecsBuilder_.getMessage();
}
}
/**
*
* Client can only use compression codecs from this set to write messages to topic.
* Otherwise session will be closed with BAD_REQUEST.
*
*
* .Ydb.Topic.SupportedCodecs supported_codecs = 4;
*/
public Builder setSupportedCodecs(tech.ydb.proto.topic.YdbTopic.SupportedCodecs value) {
if (supportedCodecsBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
supportedCodecs_ = value;
} else {
supportedCodecsBuilder_.setMessage(value);
}
bitField0_ |= 0x00000008;
onChanged();
return this;
}
/**
*
* Client can only use compression codecs from this set to write messages to topic.
* Otherwise session will be closed with BAD_REQUEST.
*
*
* .Ydb.Topic.SupportedCodecs supported_codecs = 4;
*/
public Builder setSupportedCodecs(
tech.ydb.proto.topic.YdbTopic.SupportedCodecs.Builder builderForValue) {
if (supportedCodecsBuilder_ == null) {
supportedCodecs_ = builderForValue.build();
} else {
supportedCodecsBuilder_.setMessage(builderForValue.build());
}
bitField0_ |= 0x00000008;
onChanged();
return this;
}
/**
*
* Client can only use compression codecs from this set to write messages to topic.
* Otherwise session will be closed with BAD_REQUEST.
*
*
* .Ydb.Topic.SupportedCodecs supported_codecs = 4;
*/
public Builder mergeSupportedCodecs(tech.ydb.proto.topic.YdbTopic.SupportedCodecs value) {
if (supportedCodecsBuilder_ == null) {
if (((bitField0_ & 0x00000008) != 0) &&
supportedCodecs_ != null &&
supportedCodecs_ != tech.ydb.proto.topic.YdbTopic.SupportedCodecs.getDefaultInstance()) {
getSupportedCodecsBuilder().mergeFrom(value);
} else {
supportedCodecs_ = value;
}
} else {
supportedCodecsBuilder_.mergeFrom(value);
}
if (supportedCodecs_ != null) {
bitField0_ |= 0x00000008;
onChanged();
}
return this;
}
/**
*
* Client can only use compression codecs from this set to write messages to topic.
* Otherwise session will be closed with BAD_REQUEST.
*
*
* .Ydb.Topic.SupportedCodecs supported_codecs = 4;
*/
public Builder clearSupportedCodecs() {
bitField0_ = (bitField0_ & ~0x00000008);
supportedCodecs_ = null;
if (supportedCodecsBuilder_ != null) {
supportedCodecsBuilder_.dispose();
supportedCodecsBuilder_ = null;
}
onChanged();
return this;
}
/**
*
* Client can only use compression codecs from this set to write messages to topic.
* Otherwise session will be closed with BAD_REQUEST.
*
*
* .Ydb.Topic.SupportedCodecs supported_codecs = 4;
*/
public tech.ydb.proto.topic.YdbTopic.SupportedCodecs.Builder getSupportedCodecsBuilder() {
bitField0_ |= 0x00000008;
onChanged();
return getSupportedCodecsFieldBuilder().getBuilder();
}
/**
*
* Client can only use compression codecs from this set to write messages to topic.
* Otherwise session will be closed with BAD_REQUEST.
*
*
* .Ydb.Topic.SupportedCodecs supported_codecs = 4;
*/
public tech.ydb.proto.topic.YdbTopic.SupportedCodecsOrBuilder getSupportedCodecsOrBuilder() {
if (supportedCodecsBuilder_ != null) {
return supportedCodecsBuilder_.getMessageOrBuilder();
} else {
return supportedCodecs_ == null ?
tech.ydb.proto.topic.YdbTopic.SupportedCodecs.getDefaultInstance() : supportedCodecs_;
}
}
/**
*
* Client can only use compression codecs from this set to write messages to topic.
* Otherwise session will be closed with BAD_REQUEST.
*
*
* .Ydb.Topic.SupportedCodecs supported_codecs = 4;
*/
private com.google.protobuf.SingleFieldBuilderV3<
tech.ydb.proto.topic.YdbTopic.SupportedCodecs, tech.ydb.proto.topic.YdbTopic.SupportedCodecs.Builder, tech.ydb.proto.topic.YdbTopic.SupportedCodecsOrBuilder>
getSupportedCodecsFieldBuilder() {
if (supportedCodecsBuilder_ == null) {
supportedCodecsBuilder_ = new com.google.protobuf.SingleFieldBuilderV3<
tech.ydb.proto.topic.YdbTopic.SupportedCodecs, tech.ydb.proto.topic.YdbTopic.SupportedCodecs.Builder, tech.ydb.proto.topic.YdbTopic.SupportedCodecsOrBuilder>(
getSupportedCodecs(),
getParentForChildren(),
isClean());
supportedCodecs_ = null;
}
return supportedCodecsBuilder_;
}
@java.lang.Override
public final Builder setUnknownFields(
final com.google.protobuf.UnknownFieldSet unknownFields) {
return super.setUnknownFields(unknownFields);
}
@java.lang.Override
public final Builder mergeUnknownFields(
final com.google.protobuf.UnknownFieldSet unknownFields) {
return super.mergeUnknownFields(unknownFields);
}
// @@protoc_insertion_point(builder_scope:Ydb.Topic.StreamWriteMessage.InitResponse)
}
// @@protoc_insertion_point(class_scope:Ydb.Topic.StreamWriteMessage.InitResponse)
private static final tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitResponse DEFAULT_INSTANCE;
static {
DEFAULT_INSTANCE = new tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitResponse();
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitResponse getDefaultInstance() {
return DEFAULT_INSTANCE;
}
private static final com.google.protobuf.Parser
PARSER = new com.google.protobuf.AbstractParser() {
@java.lang.Override
public InitResponse parsePartialFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
Builder builder = newBuilder();
try {
builder.mergeFrom(input, extensionRegistry);
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.setUnfinishedMessage(builder.buildPartial());
} catch (com.google.protobuf.UninitializedMessageException e) {
throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial());
} catch (java.io.IOException e) {
throw new com.google.protobuf.InvalidProtocolBufferException(e)
.setUnfinishedMessage(builder.buildPartial());
}
return builder.buildPartial();
}
};
public static com.google.protobuf.Parser parser() {
return PARSER;
}
@java.lang.Override
public com.google.protobuf.Parser getParserForType() {
return PARSER;
}
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.InitResponse getDefaultInstanceForType() {
return DEFAULT_INSTANCE;
}
}
public interface WriteRequestOrBuilder extends
// @@protoc_insertion_point(interface_extends:Ydb.Topic.StreamWriteMessage.WriteRequest)
com.google.protobuf.MessageOrBuilder {
/**
* repeated .Ydb.Topic.StreamWriteMessage.WriteRequest.MessageData messages = 1;
*/
java.util.List
getMessagesList();
/**
* repeated .Ydb.Topic.StreamWriteMessage.WriteRequest.MessageData messages = 1;
*/
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest.MessageData getMessages(int index);
/**
* repeated .Ydb.Topic.StreamWriteMessage.WriteRequest.MessageData messages = 1;
*/
int getMessagesCount();
/**
* repeated .Ydb.Topic.StreamWriteMessage.WriteRequest.MessageData messages = 1;
*/
java.util.List extends tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest.MessageDataOrBuilder>
getMessagesOrBuilderList();
/**
* repeated .Ydb.Topic.StreamWriteMessage.WriteRequest.MessageData messages = 1;
*/
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest.MessageDataOrBuilder getMessagesOrBuilder(
int index);
/**
*
* Codec that is used for data compression.
* See enum Codec above for values.
*
*
* int32 codec = 2;
* @return The codec.
*/
int getCodec();
/**
* optional .Ydb.Topic.TransactionIdentity tx = 3;
* @return Whether the tx field is set.
*/
boolean hasTx();
/**
* optional .Ydb.Topic.TransactionIdentity tx = 3;
* @return The tx.
*/
tech.ydb.proto.topic.YdbTopic.TransactionIdentity getTx();
/**
* optional .Ydb.Topic.TransactionIdentity tx = 3;
*/
tech.ydb.proto.topic.YdbTopic.TransactionIdentityOrBuilder getTxOrBuilder();
}
/**
*
* Represents portion of client messages.
*
*
* Protobuf type {@code Ydb.Topic.StreamWriteMessage.WriteRequest}
*/
public static final class WriteRequest extends
com.google.protobuf.GeneratedMessageV3 implements
// @@protoc_insertion_point(message_implements:Ydb.Topic.StreamWriteMessage.WriteRequest)
WriteRequestOrBuilder {
private static final long serialVersionUID = 0L;
// Use WriteRequest.newBuilder() to construct.
private WriteRequest(com.google.protobuf.GeneratedMessageV3.Builder> builder) {
super(builder);
}
private WriteRequest() {
messages_ = java.util.Collections.emptyList();
}
@java.lang.Override
@SuppressWarnings({"unused"})
protected java.lang.Object newInstance(
UnusedPrivateParameter unused) {
return new WriteRequest();
}
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_StreamWriteMessage_WriteRequest_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_StreamWriteMessage_WriteRequest_fieldAccessorTable
.ensureFieldAccessorsInitialized(
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest.class, tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest.Builder.class);
}
public interface MessageDataOrBuilder extends
// @@protoc_insertion_point(interface_extends:Ydb.Topic.StreamWriteMessage.WriteRequest.MessageData)
com.google.protobuf.MessageOrBuilder {
/**
*
* Message sequence number, provided by client for deduplication.
* Starts at 1
*
*
* int64 seq_no = 1;
* @return The seqNo.
*/
long getSeqNo();
/**
*
* Creation timestamp
*
*
* .google.protobuf.Timestamp created_at = 2;
* @return Whether the createdAt field is set.
*/
boolean hasCreatedAt();
/**
*
* Creation timestamp
*
*
* .google.protobuf.Timestamp created_at = 2;
* @return The createdAt.
*/
com.google.protobuf.Timestamp getCreatedAt();
/**
*
* Creation timestamp
*
*
* .google.protobuf.Timestamp created_at = 2;
*/
com.google.protobuf.TimestampOrBuilder getCreatedAtOrBuilder();
/**
*
* Compressed client message body.
*
*
* bytes data = 3;
* @return The data.
*/
com.google.protobuf.ByteString getData();
/**
*
* Uncompressed size of client message body.
*
*
* int64 uncompressed_size = 4;
* @return The uncompressedSize.
*/
long getUncompressedSize();
/**
*
* All messages with given pair (producer_id, message_group_id) go to single partition in order of writes.
*
*
* string message_group_id = 5 [(.Ydb.length) = { ... }
* @return Whether the messageGroupId field is set.
*/
boolean hasMessageGroupId();
/**
*
* All messages with given pair (producer_id, message_group_id) go to single partition in order of writes.
*
*
* string message_group_id = 5 [(.Ydb.length) = { ... }
* @return The messageGroupId.
*/
java.lang.String getMessageGroupId();
/**
*
* All messages with given pair (producer_id, message_group_id) go to single partition in order of writes.
*
*
* string message_group_id = 5 [(.Ydb.length) = { ... }
* @return The bytes for messageGroupId.
*/
com.google.protobuf.ByteString
getMessageGroupIdBytes();
/**
*
* Explicit partition id to write to.
*
*
* int64 partition_id = 6;
* @return Whether the partitionId field is set.
*/
boolean hasPartitionId();
/**
*
* Explicit partition id to write to.
*
*
* int64 partition_id = 6;
* @return The partitionId.
*/
long getPartitionId();
/**
*
* Explicit partition location to write to.
*
*
* .Ydb.Topic.PartitionWithGeneration partition_with_generation = 8;
* @return Whether the partitionWithGeneration field is set.
*/
boolean hasPartitionWithGeneration();
/**
*
* Explicit partition location to write to.
*
*
* .Ydb.Topic.PartitionWithGeneration partition_with_generation = 8;
* @return The partitionWithGeneration.
*/
tech.ydb.proto.topic.YdbTopic.PartitionWithGeneration getPartitionWithGeneration();
/**
*
* Explicit partition location to write to.
*
*
* .Ydb.Topic.PartitionWithGeneration partition_with_generation = 8;
*/
tech.ydb.proto.topic.YdbTopic.PartitionWithGenerationOrBuilder getPartitionWithGenerationOrBuilder();
/**
*
* Message metadata. Overall size is limited to 4096 symbols (all keys and values combined).
*
*
* repeated .Ydb.Topic.MetadataItem metadata_items = 7 [(.Ydb.size) = { ... }
*/
java.util.List
getMetadataItemsList();
/**
*
* Message metadata. Overall size is limited to 4096 symbols (all keys and values combined).
*
*
* repeated .Ydb.Topic.MetadataItem metadata_items = 7 [(.Ydb.size) = { ... }
*/
tech.ydb.proto.topic.YdbTopic.MetadataItem getMetadataItems(int index);
/**
*
* Message metadata. Overall size is limited to 4096 symbols (all keys and values combined).
*
*
* repeated .Ydb.Topic.MetadataItem metadata_items = 7 [(.Ydb.size) = { ... }
*/
int getMetadataItemsCount();
/**
*
* Message metadata. Overall size is limited to 4096 symbols (all keys and values combined).
*
*
* repeated .Ydb.Topic.MetadataItem metadata_items = 7 [(.Ydb.size) = { ... }
*/
java.util.List extends tech.ydb.proto.topic.YdbTopic.MetadataItemOrBuilder>
getMetadataItemsOrBuilderList();
/**
*
* Message metadata. Overall size is limited to 4096 symbols (all keys and values combined).
*
*
* repeated .Ydb.Topic.MetadataItem metadata_items = 7 [(.Ydb.size) = { ... }
*/
tech.ydb.proto.topic.YdbTopic.MetadataItemOrBuilder getMetadataItemsOrBuilder(
int index);
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest.MessageData.PartitioningCase getPartitioningCase();
}
/**
* Protobuf type {@code Ydb.Topic.StreamWriteMessage.WriteRequest.MessageData}
*/
public static final class MessageData extends
com.google.protobuf.GeneratedMessageV3 implements
// @@protoc_insertion_point(message_implements:Ydb.Topic.StreamWriteMessage.WriteRequest.MessageData)
MessageDataOrBuilder {
private static final long serialVersionUID = 0L;
// Use MessageData.newBuilder() to construct.
private MessageData(com.google.protobuf.GeneratedMessageV3.Builder> builder) {
super(builder);
}
private MessageData() {
data_ = com.google.protobuf.ByteString.EMPTY;
metadataItems_ = java.util.Collections.emptyList();
}
@java.lang.Override
@SuppressWarnings({"unused"})
protected java.lang.Object newInstance(
UnusedPrivateParameter unused) {
return new MessageData();
}
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_StreamWriteMessage_WriteRequest_MessageData_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_StreamWriteMessage_WriteRequest_MessageData_fieldAccessorTable
.ensureFieldAccessorsInitialized(
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest.MessageData.class, tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest.MessageData.Builder.class);
}
private int bitField0_;
private int partitioningCase_ = 0;
@SuppressWarnings("serial")
private java.lang.Object partitioning_;
public enum PartitioningCase
implements com.google.protobuf.Internal.EnumLite,
com.google.protobuf.AbstractMessage.InternalOneOfEnum {
MESSAGE_GROUP_ID(5),
PARTITION_ID(6),
PARTITION_WITH_GENERATION(8),
PARTITIONING_NOT_SET(0);
private final int value;
private PartitioningCase(int value) {
this.value = value;
}
/**
* @param value The number of the enum to look for.
* @return The enum associated with the given number.
* @deprecated Use {@link #forNumber(int)} instead.
*/
@java.lang.Deprecated
public static PartitioningCase valueOf(int value) {
return forNumber(value);
}
public static PartitioningCase forNumber(int value) {
switch (value) {
case 5: return MESSAGE_GROUP_ID;
case 6: return PARTITION_ID;
case 8: return PARTITION_WITH_GENERATION;
case 0: return PARTITIONING_NOT_SET;
default: return null;
}
}
public int getNumber() {
return this.value;
}
};
public PartitioningCase
getPartitioningCase() {
return PartitioningCase.forNumber(
partitioningCase_);
}
public static final int SEQ_NO_FIELD_NUMBER = 1;
private long seqNo_ = 0L;
/**
*
* Message sequence number, provided by client for deduplication.
* Starts at 1
*
*
* int64 seq_no = 1;
* @return The seqNo.
*/
@java.lang.Override
public long getSeqNo() {
return seqNo_;
}
public static final int CREATED_AT_FIELD_NUMBER = 2;
private com.google.protobuf.Timestamp createdAt_;
/**
*
* Creation timestamp
*
*
* .google.protobuf.Timestamp created_at = 2;
* @return Whether the createdAt field is set.
*/
@java.lang.Override
public boolean hasCreatedAt() {
return ((bitField0_ & 0x00000001) != 0);
}
/**
*
* Creation timestamp
*
*
* .google.protobuf.Timestamp created_at = 2;
* @return The createdAt.
*/
@java.lang.Override
public com.google.protobuf.Timestamp getCreatedAt() {
return createdAt_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : createdAt_;
}
/**
*
* Creation timestamp
*
*
* .google.protobuf.Timestamp created_at = 2;
*/
@java.lang.Override
public com.google.protobuf.TimestampOrBuilder getCreatedAtOrBuilder() {
return createdAt_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : createdAt_;
}
public static final int DATA_FIELD_NUMBER = 3;
private com.google.protobuf.ByteString data_ = com.google.protobuf.ByteString.EMPTY;
/**
*
* Compressed client message body.
*
*
* bytes data = 3;
* @return The data.
*/
@java.lang.Override
public com.google.protobuf.ByteString getData() {
return data_;
}
public static final int UNCOMPRESSED_SIZE_FIELD_NUMBER = 4;
private long uncompressedSize_ = 0L;
/**
*
* Uncompressed size of client message body.
*
*
* int64 uncompressed_size = 4;
* @return The uncompressedSize.
*/
@java.lang.Override
public long getUncompressedSize() {
return uncompressedSize_;
}
public static final int MESSAGE_GROUP_ID_FIELD_NUMBER = 5;
/**
*
* All messages with given pair (producer_id, message_group_id) go to single partition in order of writes.
*
*
* string message_group_id = 5 [(.Ydb.length) = { ... }
* @return Whether the messageGroupId field is set.
*/
public boolean hasMessageGroupId() {
return partitioningCase_ == 5;
}
/**
*
* All messages with given pair (producer_id, message_group_id) go to single partition in order of writes.
*
*
* string message_group_id = 5 [(.Ydb.length) = { ... }
* @return The messageGroupId.
*/
public java.lang.String getMessageGroupId() {
java.lang.Object ref = "";
if (partitioningCase_ == 5) {
ref = partitioning_;
}
if (ref instanceof java.lang.String) {
return (java.lang.String) ref;
} else {
com.google.protobuf.ByteString bs =
(com.google.protobuf.ByteString) ref;
java.lang.String s = bs.toStringUtf8();
if (partitioningCase_ == 5) {
partitioning_ = s;
}
return s;
}
}
/**
*
* All messages with given pair (producer_id, message_group_id) go to single partition in order of writes.
*
*
* string message_group_id = 5 [(.Ydb.length) = { ... }
* @return The bytes for messageGroupId.
*/
public com.google.protobuf.ByteString
getMessageGroupIdBytes() {
java.lang.Object ref = "";
if (partitioningCase_ == 5) {
ref = partitioning_;
}
if (ref instanceof java.lang.String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
if (partitioningCase_ == 5) {
partitioning_ = b;
}
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
public static final int PARTITION_ID_FIELD_NUMBER = 6;
/**
*
* Explicit partition id to write to.
*
*
* int64 partition_id = 6;
* @return Whether the partitionId field is set.
*/
@java.lang.Override
public boolean hasPartitionId() {
return partitioningCase_ == 6;
}
/**
*
* Explicit partition id to write to.
*
*
* int64 partition_id = 6;
* @return The partitionId.
*/
@java.lang.Override
public long getPartitionId() {
if (partitioningCase_ == 6) {
return (java.lang.Long) partitioning_;
}
return 0L;
}
public static final int PARTITION_WITH_GENERATION_FIELD_NUMBER = 8;
/**
*
* Explicit partition location to write to.
*
*
* .Ydb.Topic.PartitionWithGeneration partition_with_generation = 8;
* @return Whether the partitionWithGeneration field is set.
*/
@java.lang.Override
public boolean hasPartitionWithGeneration() {
return partitioningCase_ == 8;
}
/**
*
* Explicit partition location to write to.
*
*
* .Ydb.Topic.PartitionWithGeneration partition_with_generation = 8;
* @return The partitionWithGeneration.
*/
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.PartitionWithGeneration getPartitionWithGeneration() {
if (partitioningCase_ == 8) {
return (tech.ydb.proto.topic.YdbTopic.PartitionWithGeneration) partitioning_;
}
return tech.ydb.proto.topic.YdbTopic.PartitionWithGeneration.getDefaultInstance();
}
/**
*
* Explicit partition location to write to.
*
*
* .Ydb.Topic.PartitionWithGeneration partition_with_generation = 8;
*/
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.PartitionWithGenerationOrBuilder getPartitionWithGenerationOrBuilder() {
if (partitioningCase_ == 8) {
return (tech.ydb.proto.topic.YdbTopic.PartitionWithGeneration) partitioning_;
}
return tech.ydb.proto.topic.YdbTopic.PartitionWithGeneration.getDefaultInstance();
}
public static final int METADATA_ITEMS_FIELD_NUMBER = 7;
@SuppressWarnings("serial")
private java.util.List metadataItems_;
/**
*
* Message metadata. Overall size is limited to 4096 symbols (all keys and values combined).
*
*
* repeated .Ydb.Topic.MetadataItem metadata_items = 7 [(.Ydb.size) = { ... }
*/
@java.lang.Override
public java.util.List getMetadataItemsList() {
return metadataItems_;
}
/**
*
* Message metadata. Overall size is limited to 4096 symbols (all keys and values combined).
*
*
* repeated .Ydb.Topic.MetadataItem metadata_items = 7 [(.Ydb.size) = { ... }
*/
@java.lang.Override
public java.util.List extends tech.ydb.proto.topic.YdbTopic.MetadataItemOrBuilder>
getMetadataItemsOrBuilderList() {
return metadataItems_;
}
/**
*
* Message metadata. Overall size is limited to 4096 symbols (all keys and values combined).
*
*
* repeated .Ydb.Topic.MetadataItem metadata_items = 7 [(.Ydb.size) = { ... }
*/
@java.lang.Override
public int getMetadataItemsCount() {
return metadataItems_.size();
}
/**
*
* Message metadata. Overall size is limited to 4096 symbols (all keys and values combined).
*
*
* repeated .Ydb.Topic.MetadataItem metadata_items = 7 [(.Ydb.size) = { ... }
*/
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.MetadataItem getMetadataItems(int index) {
return metadataItems_.get(index);
}
/**
*
* Message metadata. Overall size is limited to 4096 symbols (all keys and values combined).
*
*
* repeated .Ydb.Topic.MetadataItem metadata_items = 7 [(.Ydb.size) = { ... }
*/
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.MetadataItemOrBuilder getMetadataItemsOrBuilder(
int index) {
return metadataItems_.get(index);
}
private byte memoizedIsInitialized = -1;
@java.lang.Override
public final boolean isInitialized() {
byte isInitialized = memoizedIsInitialized;
if (isInitialized == 1) return true;
if (isInitialized == 0) return false;
memoizedIsInitialized = 1;
return true;
}
@java.lang.Override
public void writeTo(com.google.protobuf.CodedOutputStream output)
throws java.io.IOException {
if (seqNo_ != 0L) {
output.writeInt64(1, seqNo_);
}
if (((bitField0_ & 0x00000001) != 0)) {
output.writeMessage(2, getCreatedAt());
}
if (!data_.isEmpty()) {
output.writeBytes(3, data_);
}
if (uncompressedSize_ != 0L) {
output.writeInt64(4, uncompressedSize_);
}
if (partitioningCase_ == 5) {
com.google.protobuf.GeneratedMessageV3.writeString(output, 5, partitioning_);
}
if (partitioningCase_ == 6) {
output.writeInt64(
6, (long)((java.lang.Long) partitioning_));
}
for (int i = 0; i < metadataItems_.size(); i++) {
output.writeMessage(7, metadataItems_.get(i));
}
if (partitioningCase_ == 8) {
output.writeMessage(8, (tech.ydb.proto.topic.YdbTopic.PartitionWithGeneration) partitioning_);
}
getUnknownFields().writeTo(output);
}
@java.lang.Override
public int getSerializedSize() {
int size = memoizedSize;
if (size != -1) return size;
size = 0;
if (seqNo_ != 0L) {
size += com.google.protobuf.CodedOutputStream
.computeInt64Size(1, seqNo_);
}
if (((bitField0_ & 0x00000001) != 0)) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(2, getCreatedAt());
}
if (!data_.isEmpty()) {
size += com.google.protobuf.CodedOutputStream
.computeBytesSize(3, data_);
}
if (uncompressedSize_ != 0L) {
size += com.google.protobuf.CodedOutputStream
.computeInt64Size(4, uncompressedSize_);
}
if (partitioningCase_ == 5) {
size += com.google.protobuf.GeneratedMessageV3.computeStringSize(5, partitioning_);
}
if (partitioningCase_ == 6) {
size += com.google.protobuf.CodedOutputStream
.computeInt64Size(
6, (long)((java.lang.Long) partitioning_));
}
for (int i = 0; i < metadataItems_.size(); i++) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(7, metadataItems_.get(i));
}
if (partitioningCase_ == 8) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(8, (tech.ydb.proto.topic.YdbTopic.PartitionWithGeneration) partitioning_);
}
size += getUnknownFields().getSerializedSize();
memoizedSize = size;
return size;
}
@java.lang.Override
public boolean equals(final java.lang.Object obj) {
if (obj == this) {
return true;
}
if (!(obj instanceof tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest.MessageData)) {
return super.equals(obj);
}
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest.MessageData other = (tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest.MessageData) obj;
if (getSeqNo()
!= other.getSeqNo()) return false;
if (hasCreatedAt() != other.hasCreatedAt()) return false;
if (hasCreatedAt()) {
if (!getCreatedAt()
.equals(other.getCreatedAt())) return false;
}
if (!getData()
.equals(other.getData())) return false;
if (getUncompressedSize()
!= other.getUncompressedSize()) return false;
if (!getMetadataItemsList()
.equals(other.getMetadataItemsList())) return false;
if (!getPartitioningCase().equals(other.getPartitioningCase())) return false;
switch (partitioningCase_) {
case 5:
if (!getMessageGroupId()
.equals(other.getMessageGroupId())) return false;
break;
case 6:
if (getPartitionId()
!= other.getPartitionId()) return false;
break;
case 8:
if (!getPartitionWithGeneration()
.equals(other.getPartitionWithGeneration())) return false;
break;
case 0:
default:
}
if (!getUnknownFields().equals(other.getUnknownFields())) return false;
return true;
}
@java.lang.Override
public int hashCode() {
if (memoizedHashCode != 0) {
return memoizedHashCode;
}
int hash = 41;
hash = (19 * hash) + getDescriptor().hashCode();
hash = (37 * hash) + SEQ_NO_FIELD_NUMBER;
hash = (53 * hash) + com.google.protobuf.Internal.hashLong(
getSeqNo());
if (hasCreatedAt()) {
hash = (37 * hash) + CREATED_AT_FIELD_NUMBER;
hash = (53 * hash) + getCreatedAt().hashCode();
}
hash = (37 * hash) + DATA_FIELD_NUMBER;
hash = (53 * hash) + getData().hashCode();
hash = (37 * hash) + UNCOMPRESSED_SIZE_FIELD_NUMBER;
hash = (53 * hash) + com.google.protobuf.Internal.hashLong(
getUncompressedSize());
if (getMetadataItemsCount() > 0) {
hash = (37 * hash) + METADATA_ITEMS_FIELD_NUMBER;
hash = (53 * hash) + getMetadataItemsList().hashCode();
}
switch (partitioningCase_) {
case 5:
hash = (37 * hash) + MESSAGE_GROUP_ID_FIELD_NUMBER;
hash = (53 * hash) + getMessageGroupId().hashCode();
break;
case 6:
hash = (37 * hash) + PARTITION_ID_FIELD_NUMBER;
hash = (53 * hash) + com.google.protobuf.Internal.hashLong(
getPartitionId());
break;
case 8:
hash = (37 * hash) + PARTITION_WITH_GENERATION_FIELD_NUMBER;
hash = (53 * hash) + getPartitionWithGeneration().hashCode();
break;
case 0:
default:
}
hash = (29 * hash) + getUnknownFields().hashCode();
memoizedHashCode = hash;
return hash;
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest.MessageData parseFrom(
java.nio.ByteBuffer data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest.MessageData parseFrom(
java.nio.ByteBuffer data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest.MessageData parseFrom(
com.google.protobuf.ByteString data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest.MessageData parseFrom(
com.google.protobuf.ByteString data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest.MessageData parseFrom(byte[] data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest.MessageData parseFrom(
byte[] data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest.MessageData parseFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest.MessageData parseFrom(
java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest.MessageData parseDelimitedFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input);
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest.MessageData parseDelimitedFrom(
java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest.MessageData parseFrom(
com.google.protobuf.CodedInputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest.MessageData parseFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry);
}
@java.lang.Override
public Builder newBuilderForType() { return newBuilder(); }
public static Builder newBuilder() {
return DEFAULT_INSTANCE.toBuilder();
}
public static Builder newBuilder(tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest.MessageData prototype) {
return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
}
@java.lang.Override
public Builder toBuilder() {
return this == DEFAULT_INSTANCE
? new Builder() : new Builder().mergeFrom(this);
}
@java.lang.Override
protected Builder newBuilderForType(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
Builder builder = new Builder(parent);
return builder;
}
/**
* Protobuf type {@code Ydb.Topic.StreamWriteMessage.WriteRequest.MessageData}
*/
public static final class Builder extends
com.google.protobuf.GeneratedMessageV3.Builder implements
// @@protoc_insertion_point(builder_implements:Ydb.Topic.StreamWriteMessage.WriteRequest.MessageData)
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest.MessageDataOrBuilder {
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_StreamWriteMessage_WriteRequest_MessageData_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_StreamWriteMessage_WriteRequest_MessageData_fieldAccessorTable
.ensureFieldAccessorsInitialized(
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest.MessageData.class, tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest.MessageData.Builder.class);
}
// Construct using tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest.MessageData.newBuilder()
private Builder() {
maybeForceBuilderInitialization();
}
private Builder(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
super(parent);
maybeForceBuilderInitialization();
}
private void maybeForceBuilderInitialization() {
if (com.google.protobuf.GeneratedMessageV3
.alwaysUseFieldBuilders) {
getCreatedAtFieldBuilder();
getMetadataItemsFieldBuilder();
}
}
@java.lang.Override
public Builder clear() {
super.clear();
bitField0_ = 0;
seqNo_ = 0L;
createdAt_ = null;
if (createdAtBuilder_ != null) {
createdAtBuilder_.dispose();
createdAtBuilder_ = null;
}
data_ = com.google.protobuf.ByteString.EMPTY;
uncompressedSize_ = 0L;
if (partitionWithGenerationBuilder_ != null) {
partitionWithGenerationBuilder_.clear();
}
if (metadataItemsBuilder_ == null) {
metadataItems_ = java.util.Collections.emptyList();
} else {
metadataItems_ = null;
metadataItemsBuilder_.clear();
}
bitField0_ = (bitField0_ & ~0x00000080);
partitioningCase_ = 0;
partitioning_ = null;
return this;
}
@java.lang.Override
public com.google.protobuf.Descriptors.Descriptor
getDescriptorForType() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_StreamWriteMessage_WriteRequest_MessageData_descriptor;
}
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest.MessageData getDefaultInstanceForType() {
return tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest.MessageData.getDefaultInstance();
}
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest.MessageData build() {
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest.MessageData result = buildPartial();
if (!result.isInitialized()) {
throw newUninitializedMessageException(result);
}
return result;
}
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest.MessageData buildPartial() {
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest.MessageData result = new tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest.MessageData(this);
buildPartialRepeatedFields(result);
if (bitField0_ != 0) { buildPartial0(result); }
buildPartialOneofs(result);
onBuilt();
return result;
}
private void buildPartialRepeatedFields(tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest.MessageData result) {
if (metadataItemsBuilder_ == null) {
if (((bitField0_ & 0x00000080) != 0)) {
metadataItems_ = java.util.Collections.unmodifiableList(metadataItems_);
bitField0_ = (bitField0_ & ~0x00000080);
}
result.metadataItems_ = metadataItems_;
} else {
result.metadataItems_ = metadataItemsBuilder_.build();
}
}
private void buildPartial0(tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest.MessageData result) {
int from_bitField0_ = bitField0_;
if (((from_bitField0_ & 0x00000001) != 0)) {
result.seqNo_ = seqNo_;
}
int to_bitField0_ = 0;
if (((from_bitField0_ & 0x00000002) != 0)) {
result.createdAt_ = createdAtBuilder_ == null
? createdAt_
: createdAtBuilder_.build();
to_bitField0_ |= 0x00000001;
}
if (((from_bitField0_ & 0x00000004) != 0)) {
result.data_ = data_;
}
if (((from_bitField0_ & 0x00000008) != 0)) {
result.uncompressedSize_ = uncompressedSize_;
}
result.bitField0_ |= to_bitField0_;
}
private void buildPartialOneofs(tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest.MessageData result) {
result.partitioningCase_ = partitioningCase_;
result.partitioning_ = this.partitioning_;
if (partitioningCase_ == 8 &&
partitionWithGenerationBuilder_ != null) {
result.partitioning_ = partitionWithGenerationBuilder_.build();
}
}
@java.lang.Override
public Builder clone() {
return super.clone();
}
@java.lang.Override
public Builder setField(
com.google.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) {
return super.setField(field, value);
}
@java.lang.Override
public Builder clearField(
com.google.protobuf.Descriptors.FieldDescriptor field) {
return super.clearField(field);
}
@java.lang.Override
public Builder clearOneof(
com.google.protobuf.Descriptors.OneofDescriptor oneof) {
return super.clearOneof(oneof);
}
@java.lang.Override
public Builder setRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
int index, java.lang.Object value) {
return super.setRepeatedField(field, index, value);
}
@java.lang.Override
public Builder addRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) {
return super.addRepeatedField(field, value);
}
@java.lang.Override
public Builder mergeFrom(com.google.protobuf.Message other) {
if (other instanceof tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest.MessageData) {
return mergeFrom((tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest.MessageData)other);
} else {
super.mergeFrom(other);
return this;
}
}
public Builder mergeFrom(tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest.MessageData other) {
if (other == tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest.MessageData.getDefaultInstance()) return this;
if (other.getSeqNo() != 0L) {
setSeqNo(other.getSeqNo());
}
if (other.hasCreatedAt()) {
mergeCreatedAt(other.getCreatedAt());
}
if (other.getData() != com.google.protobuf.ByteString.EMPTY) {
setData(other.getData());
}
if (other.getUncompressedSize() != 0L) {
setUncompressedSize(other.getUncompressedSize());
}
if (metadataItemsBuilder_ == null) {
if (!other.metadataItems_.isEmpty()) {
if (metadataItems_.isEmpty()) {
metadataItems_ = other.metadataItems_;
bitField0_ = (bitField0_ & ~0x00000080);
} else {
ensureMetadataItemsIsMutable();
metadataItems_.addAll(other.metadataItems_);
}
onChanged();
}
} else {
if (!other.metadataItems_.isEmpty()) {
if (metadataItemsBuilder_.isEmpty()) {
metadataItemsBuilder_.dispose();
metadataItemsBuilder_ = null;
metadataItems_ = other.metadataItems_;
bitField0_ = (bitField0_ & ~0x00000080);
metadataItemsBuilder_ =
com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders ?
getMetadataItemsFieldBuilder() : null;
} else {
metadataItemsBuilder_.addAllMessages(other.metadataItems_);
}
}
}
switch (other.getPartitioningCase()) {
case MESSAGE_GROUP_ID: {
partitioningCase_ = 5;
partitioning_ = other.partitioning_;
onChanged();
break;
}
case PARTITION_ID: {
setPartitionId(other.getPartitionId());
break;
}
case PARTITION_WITH_GENERATION: {
mergePartitionWithGeneration(other.getPartitionWithGeneration());
break;
}
case PARTITIONING_NOT_SET: {
break;
}
}
this.mergeUnknownFields(other.getUnknownFields());
onChanged();
return this;
}
@java.lang.Override
public final boolean isInitialized() {
return true;
}
@java.lang.Override
public Builder mergeFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
if (extensionRegistry == null) {
throw new java.lang.NullPointerException();
}
try {
boolean done = false;
while (!done) {
int tag = input.readTag();
switch (tag) {
case 0:
done = true;
break;
case 8: {
seqNo_ = input.readInt64();
bitField0_ |= 0x00000001;
break;
} // case 8
case 18: {
input.readMessage(
getCreatedAtFieldBuilder().getBuilder(),
extensionRegistry);
bitField0_ |= 0x00000002;
break;
} // case 18
case 26: {
data_ = input.readBytes();
bitField0_ |= 0x00000004;
break;
} // case 26
case 32: {
uncompressedSize_ = input.readInt64();
bitField0_ |= 0x00000008;
break;
} // case 32
case 42: {
java.lang.String s = input.readStringRequireUtf8();
partitioningCase_ = 5;
partitioning_ = s;
break;
} // case 42
case 48: {
partitioning_ = input.readInt64();
partitioningCase_ = 6;
break;
} // case 48
case 58: {
tech.ydb.proto.topic.YdbTopic.MetadataItem m =
input.readMessage(
tech.ydb.proto.topic.YdbTopic.MetadataItem.parser(),
extensionRegistry);
if (metadataItemsBuilder_ == null) {
ensureMetadataItemsIsMutable();
metadataItems_.add(m);
} else {
metadataItemsBuilder_.addMessage(m);
}
break;
} // case 58
case 66: {
input.readMessage(
getPartitionWithGenerationFieldBuilder().getBuilder(),
extensionRegistry);
partitioningCase_ = 8;
break;
} // case 66
default: {
if (!super.parseUnknownField(input, extensionRegistry, tag)) {
done = true; // was an endgroup tag
}
break;
} // default:
} // switch (tag)
} // while (!done)
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.unwrapIOException();
} finally {
onChanged();
} // finally
return this;
}
private int partitioningCase_ = 0;
private java.lang.Object partitioning_;
public PartitioningCase
getPartitioningCase() {
return PartitioningCase.forNumber(
partitioningCase_);
}
public Builder clearPartitioning() {
partitioningCase_ = 0;
partitioning_ = null;
onChanged();
return this;
}
private int bitField0_;
private long seqNo_ ;
/**
*
* Message sequence number, provided by client for deduplication.
* Starts at 1
*
*
* int64 seq_no = 1;
* @return The seqNo.
*/
@java.lang.Override
public long getSeqNo() {
return seqNo_;
}
/**
*
* Message sequence number, provided by client for deduplication.
* Starts at 1
*
*
* int64 seq_no = 1;
* @param value The seqNo to set.
* @return This builder for chaining.
*/
public Builder setSeqNo(long value) {
seqNo_ = value;
bitField0_ |= 0x00000001;
onChanged();
return this;
}
/**
*
* Message sequence number, provided by client for deduplication.
* Starts at 1
*
*
* int64 seq_no = 1;
* @return This builder for chaining.
*/
public Builder clearSeqNo() {
bitField0_ = (bitField0_ & ~0x00000001);
seqNo_ = 0L;
onChanged();
return this;
}
private com.google.protobuf.Timestamp createdAt_;
private com.google.protobuf.SingleFieldBuilderV3<
com.google.protobuf.Timestamp, com.google.protobuf.Timestamp.Builder, com.google.protobuf.TimestampOrBuilder> createdAtBuilder_;
/**
*
* Creation timestamp
*
*
* .google.protobuf.Timestamp created_at = 2;
* @return Whether the createdAt field is set.
*/
public boolean hasCreatedAt() {
return ((bitField0_ & 0x00000002) != 0);
}
/**
*
* Creation timestamp
*
*
* .google.protobuf.Timestamp created_at = 2;
* @return The createdAt.
*/
public com.google.protobuf.Timestamp getCreatedAt() {
if (createdAtBuilder_ == null) {
return createdAt_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : createdAt_;
} else {
return createdAtBuilder_.getMessage();
}
}
/**
*
* Creation timestamp
*
*
* .google.protobuf.Timestamp created_at = 2;
*/
public Builder setCreatedAt(com.google.protobuf.Timestamp value) {
if (createdAtBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
createdAt_ = value;
} else {
createdAtBuilder_.setMessage(value);
}
bitField0_ |= 0x00000002;
onChanged();
return this;
}
/**
*
* Creation timestamp
*
*
* .google.protobuf.Timestamp created_at = 2;
*/
public Builder setCreatedAt(
com.google.protobuf.Timestamp.Builder builderForValue) {
if (createdAtBuilder_ == null) {
createdAt_ = builderForValue.build();
} else {
createdAtBuilder_.setMessage(builderForValue.build());
}
bitField0_ |= 0x00000002;
onChanged();
return this;
}
/**
*
* Creation timestamp
*
*
* .google.protobuf.Timestamp created_at = 2;
*/
public Builder mergeCreatedAt(com.google.protobuf.Timestamp value) {
if (createdAtBuilder_ == null) {
if (((bitField0_ & 0x00000002) != 0) &&
createdAt_ != null &&
createdAt_ != com.google.protobuf.Timestamp.getDefaultInstance()) {
getCreatedAtBuilder().mergeFrom(value);
} else {
createdAt_ = value;
}
} else {
createdAtBuilder_.mergeFrom(value);
}
if (createdAt_ != null) {
bitField0_ |= 0x00000002;
onChanged();
}
return this;
}
/**
*
* Creation timestamp
*
*
* .google.protobuf.Timestamp created_at = 2;
*/
public Builder clearCreatedAt() {
bitField0_ = (bitField0_ & ~0x00000002);
createdAt_ = null;
if (createdAtBuilder_ != null) {
createdAtBuilder_.dispose();
createdAtBuilder_ = null;
}
onChanged();
return this;
}
/**
*
* Creation timestamp
*
*
* .google.protobuf.Timestamp created_at = 2;
*/
public com.google.protobuf.Timestamp.Builder getCreatedAtBuilder() {
bitField0_ |= 0x00000002;
onChanged();
return getCreatedAtFieldBuilder().getBuilder();
}
/**
*
* Creation timestamp
*
*
* .google.protobuf.Timestamp created_at = 2;
*/
public com.google.protobuf.TimestampOrBuilder getCreatedAtOrBuilder() {
if (createdAtBuilder_ != null) {
return createdAtBuilder_.getMessageOrBuilder();
} else {
return createdAt_ == null ?
com.google.protobuf.Timestamp.getDefaultInstance() : createdAt_;
}
}
/**
*
* Creation timestamp
*
*
* .google.protobuf.Timestamp created_at = 2;
*/
private com.google.protobuf.SingleFieldBuilderV3<
com.google.protobuf.Timestamp, com.google.protobuf.Timestamp.Builder, com.google.protobuf.TimestampOrBuilder>
getCreatedAtFieldBuilder() {
if (createdAtBuilder_ == null) {
createdAtBuilder_ = new com.google.protobuf.SingleFieldBuilderV3<
com.google.protobuf.Timestamp, com.google.protobuf.Timestamp.Builder, com.google.protobuf.TimestampOrBuilder>(
getCreatedAt(),
getParentForChildren(),
isClean());
createdAt_ = null;
}
return createdAtBuilder_;
}
private com.google.protobuf.ByteString data_ = com.google.protobuf.ByteString.EMPTY;
/**
*
* Compressed client message body.
*
*
* bytes data = 3;
* @return The data.
*/
@java.lang.Override
public com.google.protobuf.ByteString getData() {
return data_;
}
/**
*
* Compressed client message body.
*
*
* bytes data = 3;
* @param value The data to set.
* @return This builder for chaining.
*/
public Builder setData(com.google.protobuf.ByteString value) {
if (value == null) { throw new NullPointerException(); }
data_ = value;
bitField0_ |= 0x00000004;
onChanged();
return this;
}
/**
*
* Compressed client message body.
*
*
* bytes data = 3;
* @return This builder for chaining.
*/
public Builder clearData() {
bitField0_ = (bitField0_ & ~0x00000004);
data_ = getDefaultInstance().getData();
onChanged();
return this;
}
private long uncompressedSize_ ;
/**
*
* Uncompressed size of client message body.
*
*
* int64 uncompressed_size = 4;
* @return The uncompressedSize.
*/
@java.lang.Override
public long getUncompressedSize() {
return uncompressedSize_;
}
/**
*
* Uncompressed size of client message body.
*
*
* int64 uncompressed_size = 4;
* @param value The uncompressedSize to set.
* @return This builder for chaining.
*/
public Builder setUncompressedSize(long value) {
uncompressedSize_ = value;
bitField0_ |= 0x00000008;
onChanged();
return this;
}
/**
*
* Uncompressed size of client message body.
*
*
* int64 uncompressed_size = 4;
* @return This builder for chaining.
*/
public Builder clearUncompressedSize() {
bitField0_ = (bitField0_ & ~0x00000008);
uncompressedSize_ = 0L;
onChanged();
return this;
}
/**
*
* All messages with given pair (producer_id, message_group_id) go to single partition in order of writes.
*
*
* string message_group_id = 5 [(.Ydb.length) = { ... }
* @return Whether the messageGroupId field is set.
*/
@java.lang.Override
public boolean hasMessageGroupId() {
return partitioningCase_ == 5;
}
/**
*
* All messages with given pair (producer_id, message_group_id) go to single partition in order of writes.
*
*
* string message_group_id = 5 [(.Ydb.length) = { ... }
* @return The messageGroupId.
*/
@java.lang.Override
public java.lang.String getMessageGroupId() {
java.lang.Object ref = "";
if (partitioningCase_ == 5) {
ref = partitioning_;
}
if (!(ref instanceof java.lang.String)) {
com.google.protobuf.ByteString bs =
(com.google.protobuf.ByteString) ref;
java.lang.String s = bs.toStringUtf8();
if (partitioningCase_ == 5) {
partitioning_ = s;
}
return s;
} else {
return (java.lang.String) ref;
}
}
/**
*
* All messages with given pair (producer_id, message_group_id) go to single partition in order of writes.
*
*
* string message_group_id = 5 [(.Ydb.length) = { ... }
* @return The bytes for messageGroupId.
*/
@java.lang.Override
public com.google.protobuf.ByteString
getMessageGroupIdBytes() {
java.lang.Object ref = "";
if (partitioningCase_ == 5) {
ref = partitioning_;
}
if (ref instanceof String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
if (partitioningCase_ == 5) {
partitioning_ = b;
}
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
/**
*
* All messages with given pair (producer_id, message_group_id) go to single partition in order of writes.
*
*
* string message_group_id = 5 [(.Ydb.length) = { ... }
* @param value The messageGroupId to set.
* @return This builder for chaining.
*/
public Builder setMessageGroupId(
java.lang.String value) {
if (value == null) { throw new NullPointerException(); }
partitioningCase_ = 5;
partitioning_ = value;
onChanged();
return this;
}
/**
*
* All messages with given pair (producer_id, message_group_id) go to single partition in order of writes.
*
*
* string message_group_id = 5 [(.Ydb.length) = { ... }
* @return This builder for chaining.
*/
public Builder clearMessageGroupId() {
if (partitioningCase_ == 5) {
partitioningCase_ = 0;
partitioning_ = null;
onChanged();
}
return this;
}
/**
*
* All messages with given pair (producer_id, message_group_id) go to single partition in order of writes.
*
*
* string message_group_id = 5 [(.Ydb.length) = { ... }
* @param value The bytes for messageGroupId to set.
* @return This builder for chaining.
*/
public Builder setMessageGroupIdBytes(
com.google.protobuf.ByteString value) {
if (value == null) { throw new NullPointerException(); }
checkByteStringIsUtf8(value);
partitioningCase_ = 5;
partitioning_ = value;
onChanged();
return this;
}
/**
*
* Explicit partition id to write to.
*
*
* int64 partition_id = 6;
* @return Whether the partitionId field is set.
*/
public boolean hasPartitionId() {
return partitioningCase_ == 6;
}
/**
*
* Explicit partition id to write to.
*
*
* int64 partition_id = 6;
* @return The partitionId.
*/
public long getPartitionId() {
if (partitioningCase_ == 6) {
return (java.lang.Long) partitioning_;
}
return 0L;
}
/**
*
* Explicit partition id to write to.
*
*
* int64 partition_id = 6;
* @param value The partitionId to set.
* @return This builder for chaining.
*/
public Builder setPartitionId(long value) {
partitioningCase_ = 6;
partitioning_ = value;
onChanged();
return this;
}
/**
*
* Explicit partition id to write to.
*
*
* int64 partition_id = 6;
* @return This builder for chaining.
*/
public Builder clearPartitionId() {
if (partitioningCase_ == 6) {
partitioningCase_ = 0;
partitioning_ = null;
onChanged();
}
return this;
}
private com.google.protobuf.SingleFieldBuilderV3<
tech.ydb.proto.topic.YdbTopic.PartitionWithGeneration, tech.ydb.proto.topic.YdbTopic.PartitionWithGeneration.Builder, tech.ydb.proto.topic.YdbTopic.PartitionWithGenerationOrBuilder> partitionWithGenerationBuilder_;
/**
*
* Explicit partition location to write to.
*
*
* .Ydb.Topic.PartitionWithGeneration partition_with_generation = 8;
* @return Whether the partitionWithGeneration field is set.
*/
@java.lang.Override
public boolean hasPartitionWithGeneration() {
return partitioningCase_ == 8;
}
/**
*
* Explicit partition location to write to.
*
*
* .Ydb.Topic.PartitionWithGeneration partition_with_generation = 8;
* @return The partitionWithGeneration.
*/
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.PartitionWithGeneration getPartitionWithGeneration() {
if (partitionWithGenerationBuilder_ == null) {
if (partitioningCase_ == 8) {
return (tech.ydb.proto.topic.YdbTopic.PartitionWithGeneration) partitioning_;
}
return tech.ydb.proto.topic.YdbTopic.PartitionWithGeneration.getDefaultInstance();
} else {
if (partitioningCase_ == 8) {
return partitionWithGenerationBuilder_.getMessage();
}
return tech.ydb.proto.topic.YdbTopic.PartitionWithGeneration.getDefaultInstance();
}
}
/**
*
* Explicit partition location to write to.
*
*
* .Ydb.Topic.PartitionWithGeneration partition_with_generation = 8;
*/
public Builder setPartitionWithGeneration(tech.ydb.proto.topic.YdbTopic.PartitionWithGeneration value) {
if (partitionWithGenerationBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
partitioning_ = value;
onChanged();
} else {
partitionWithGenerationBuilder_.setMessage(value);
}
partitioningCase_ = 8;
return this;
}
/**
*
* Explicit partition location to write to.
*
*
* .Ydb.Topic.PartitionWithGeneration partition_with_generation = 8;
*/
public Builder setPartitionWithGeneration(
tech.ydb.proto.topic.YdbTopic.PartitionWithGeneration.Builder builderForValue) {
if (partitionWithGenerationBuilder_ == null) {
partitioning_ = builderForValue.build();
onChanged();
} else {
partitionWithGenerationBuilder_.setMessage(builderForValue.build());
}
partitioningCase_ = 8;
return this;
}
/**
*
* Explicit partition location to write to.
*
*
* .Ydb.Topic.PartitionWithGeneration partition_with_generation = 8;
*/
public Builder mergePartitionWithGeneration(tech.ydb.proto.topic.YdbTopic.PartitionWithGeneration value) {
if (partitionWithGenerationBuilder_ == null) {
if (partitioningCase_ == 8 &&
partitioning_ != tech.ydb.proto.topic.YdbTopic.PartitionWithGeneration.getDefaultInstance()) {
partitioning_ = tech.ydb.proto.topic.YdbTopic.PartitionWithGeneration.newBuilder((tech.ydb.proto.topic.YdbTopic.PartitionWithGeneration) partitioning_)
.mergeFrom(value).buildPartial();
} else {
partitioning_ = value;
}
onChanged();
} else {
if (partitioningCase_ == 8) {
partitionWithGenerationBuilder_.mergeFrom(value);
} else {
partitionWithGenerationBuilder_.setMessage(value);
}
}
partitioningCase_ = 8;
return this;
}
/**
*
* Explicit partition location to write to.
*
*
* .Ydb.Topic.PartitionWithGeneration partition_with_generation = 8;
*/
public Builder clearPartitionWithGeneration() {
if (partitionWithGenerationBuilder_ == null) {
if (partitioningCase_ == 8) {
partitioningCase_ = 0;
partitioning_ = null;
onChanged();
}
} else {
if (partitioningCase_ == 8) {
partitioningCase_ = 0;
partitioning_ = null;
}
partitionWithGenerationBuilder_.clear();
}
return this;
}
/**
*
* Explicit partition location to write to.
*
*
* .Ydb.Topic.PartitionWithGeneration partition_with_generation = 8;
*/
public tech.ydb.proto.topic.YdbTopic.PartitionWithGeneration.Builder getPartitionWithGenerationBuilder() {
return getPartitionWithGenerationFieldBuilder().getBuilder();
}
/**
*
* Explicit partition location to write to.
*
*
* .Ydb.Topic.PartitionWithGeneration partition_with_generation = 8;
*/
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.PartitionWithGenerationOrBuilder getPartitionWithGenerationOrBuilder() {
if ((partitioningCase_ == 8) && (partitionWithGenerationBuilder_ != null)) {
return partitionWithGenerationBuilder_.getMessageOrBuilder();
} else {
if (partitioningCase_ == 8) {
return (tech.ydb.proto.topic.YdbTopic.PartitionWithGeneration) partitioning_;
}
return tech.ydb.proto.topic.YdbTopic.PartitionWithGeneration.getDefaultInstance();
}
}
/**
*
* Explicit partition location to write to.
*
*
* .Ydb.Topic.PartitionWithGeneration partition_with_generation = 8;
*/
private com.google.protobuf.SingleFieldBuilderV3<
tech.ydb.proto.topic.YdbTopic.PartitionWithGeneration, tech.ydb.proto.topic.YdbTopic.PartitionWithGeneration.Builder, tech.ydb.proto.topic.YdbTopic.PartitionWithGenerationOrBuilder>
getPartitionWithGenerationFieldBuilder() {
if (partitionWithGenerationBuilder_ == null) {
if (!(partitioningCase_ == 8)) {
partitioning_ = tech.ydb.proto.topic.YdbTopic.PartitionWithGeneration.getDefaultInstance();
}
partitionWithGenerationBuilder_ = new com.google.protobuf.SingleFieldBuilderV3<
tech.ydb.proto.topic.YdbTopic.PartitionWithGeneration, tech.ydb.proto.topic.YdbTopic.PartitionWithGeneration.Builder, tech.ydb.proto.topic.YdbTopic.PartitionWithGenerationOrBuilder>(
(tech.ydb.proto.topic.YdbTopic.PartitionWithGeneration) partitioning_,
getParentForChildren(),
isClean());
partitioning_ = null;
}
partitioningCase_ = 8;
onChanged();
return partitionWithGenerationBuilder_;
}
private java.util.List metadataItems_ =
java.util.Collections.emptyList();
private void ensureMetadataItemsIsMutable() {
if (!((bitField0_ & 0x00000080) != 0)) {
metadataItems_ = new java.util.ArrayList(metadataItems_);
bitField0_ |= 0x00000080;
}
}
private com.google.protobuf.RepeatedFieldBuilderV3<
tech.ydb.proto.topic.YdbTopic.MetadataItem, tech.ydb.proto.topic.YdbTopic.MetadataItem.Builder, tech.ydb.proto.topic.YdbTopic.MetadataItemOrBuilder> metadataItemsBuilder_;
/**
*
* Message metadata. Overall size is limited to 4096 symbols (all keys and values combined).
*
*
* repeated .Ydb.Topic.MetadataItem metadata_items = 7 [(.Ydb.size) = { ... }
*/
public java.util.List getMetadataItemsList() {
if (metadataItemsBuilder_ == null) {
return java.util.Collections.unmodifiableList(metadataItems_);
} else {
return metadataItemsBuilder_.getMessageList();
}
}
/**
*
* Message metadata. Overall size is limited to 4096 symbols (all keys and values combined).
*
*
* repeated .Ydb.Topic.MetadataItem metadata_items = 7 [(.Ydb.size) = { ... }
*/
public int getMetadataItemsCount() {
if (metadataItemsBuilder_ == null) {
return metadataItems_.size();
} else {
return metadataItemsBuilder_.getCount();
}
}
/**
*
* Message metadata. Overall size is limited to 4096 symbols (all keys and values combined).
*
*
* repeated .Ydb.Topic.MetadataItem metadata_items = 7 [(.Ydb.size) = { ... }
*/
public tech.ydb.proto.topic.YdbTopic.MetadataItem getMetadataItems(int index) {
if (metadataItemsBuilder_ == null) {
return metadataItems_.get(index);
} else {
return metadataItemsBuilder_.getMessage(index);
}
}
/**
*
* Message metadata. Overall size is limited to 4096 symbols (all keys and values combined).
*
*
* repeated .Ydb.Topic.MetadataItem metadata_items = 7 [(.Ydb.size) = { ... }
*/
public Builder setMetadataItems(
int index, tech.ydb.proto.topic.YdbTopic.MetadataItem value) {
if (metadataItemsBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
ensureMetadataItemsIsMutable();
metadataItems_.set(index, value);
onChanged();
} else {
metadataItemsBuilder_.setMessage(index, value);
}
return this;
}
/**
*
* Message metadata. Overall size is limited to 4096 symbols (all keys and values combined).
*
*
* repeated .Ydb.Topic.MetadataItem metadata_items = 7 [(.Ydb.size) = { ... }
*/
public Builder setMetadataItems(
int index, tech.ydb.proto.topic.YdbTopic.MetadataItem.Builder builderForValue) {
if (metadataItemsBuilder_ == null) {
ensureMetadataItemsIsMutable();
metadataItems_.set(index, builderForValue.build());
onChanged();
} else {
metadataItemsBuilder_.setMessage(index, builderForValue.build());
}
return this;
}
/**
*
* Message metadata. Overall size is limited to 4096 symbols (all keys and values combined).
*
*
* repeated .Ydb.Topic.MetadataItem metadata_items = 7 [(.Ydb.size) = { ... }
*/
public Builder addMetadataItems(tech.ydb.proto.topic.YdbTopic.MetadataItem value) {
if (metadataItemsBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
ensureMetadataItemsIsMutable();
metadataItems_.add(value);
onChanged();
} else {
metadataItemsBuilder_.addMessage(value);
}
return this;
}
/**
*
* Message metadata. Overall size is limited to 4096 symbols (all keys and values combined).
*
*
* repeated .Ydb.Topic.MetadataItem metadata_items = 7 [(.Ydb.size) = { ... }
*/
public Builder addMetadataItems(
int index, tech.ydb.proto.topic.YdbTopic.MetadataItem value) {
if (metadataItemsBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
ensureMetadataItemsIsMutable();
metadataItems_.add(index, value);
onChanged();
} else {
metadataItemsBuilder_.addMessage(index, value);
}
return this;
}
/**
*
* Message metadata. Overall size is limited to 4096 symbols (all keys and values combined).
*
*
* repeated .Ydb.Topic.MetadataItem metadata_items = 7 [(.Ydb.size) = { ... }
*/
public Builder addMetadataItems(
tech.ydb.proto.topic.YdbTopic.MetadataItem.Builder builderForValue) {
if (metadataItemsBuilder_ == null) {
ensureMetadataItemsIsMutable();
metadataItems_.add(builderForValue.build());
onChanged();
} else {
metadataItemsBuilder_.addMessage(builderForValue.build());
}
return this;
}
/**
*
* Message metadata. Overall size is limited to 4096 symbols (all keys and values combined).
*
*
* repeated .Ydb.Topic.MetadataItem metadata_items = 7 [(.Ydb.size) = { ... }
*/
public Builder addMetadataItems(
int index, tech.ydb.proto.topic.YdbTopic.MetadataItem.Builder builderForValue) {
if (metadataItemsBuilder_ == null) {
ensureMetadataItemsIsMutable();
metadataItems_.add(index, builderForValue.build());
onChanged();
} else {
metadataItemsBuilder_.addMessage(index, builderForValue.build());
}
return this;
}
/**
*
* Message metadata. Overall size is limited to 4096 symbols (all keys and values combined).
*
*
* repeated .Ydb.Topic.MetadataItem metadata_items = 7 [(.Ydb.size) = { ... }
*/
public Builder addAllMetadataItems(
java.lang.Iterable extends tech.ydb.proto.topic.YdbTopic.MetadataItem> values) {
if (metadataItemsBuilder_ == null) {
ensureMetadataItemsIsMutable();
com.google.protobuf.AbstractMessageLite.Builder.addAll(
values, metadataItems_);
onChanged();
} else {
metadataItemsBuilder_.addAllMessages(values);
}
return this;
}
/**
*
* Message metadata. Overall size is limited to 4096 symbols (all keys and values combined).
*
*
* repeated .Ydb.Topic.MetadataItem metadata_items = 7 [(.Ydb.size) = { ... }
*/
public Builder clearMetadataItems() {
if (metadataItemsBuilder_ == null) {
metadataItems_ = java.util.Collections.emptyList();
bitField0_ = (bitField0_ & ~0x00000080);
onChanged();
} else {
metadataItemsBuilder_.clear();
}
return this;
}
/**
*
* Message metadata. Overall size is limited to 4096 symbols (all keys and values combined).
*
*
* repeated .Ydb.Topic.MetadataItem metadata_items = 7 [(.Ydb.size) = { ... }
*/
public Builder removeMetadataItems(int index) {
if (metadataItemsBuilder_ == null) {
ensureMetadataItemsIsMutable();
metadataItems_.remove(index);
onChanged();
} else {
metadataItemsBuilder_.remove(index);
}
return this;
}
/**
*
* Message metadata. Overall size is limited to 4096 symbols (all keys and values combined).
*
*
* repeated .Ydb.Topic.MetadataItem metadata_items = 7 [(.Ydb.size) = { ... }
*/
public tech.ydb.proto.topic.YdbTopic.MetadataItem.Builder getMetadataItemsBuilder(
int index) {
return getMetadataItemsFieldBuilder().getBuilder(index);
}
/**
*
* Message metadata. Overall size is limited to 4096 symbols (all keys and values combined).
*
*
* repeated .Ydb.Topic.MetadataItem metadata_items = 7 [(.Ydb.size) = { ... }
*/
public tech.ydb.proto.topic.YdbTopic.MetadataItemOrBuilder getMetadataItemsOrBuilder(
int index) {
if (metadataItemsBuilder_ == null) {
return metadataItems_.get(index); } else {
return metadataItemsBuilder_.getMessageOrBuilder(index);
}
}
/**
*
* Message metadata. Overall size is limited to 4096 symbols (all keys and values combined).
*
*
* repeated .Ydb.Topic.MetadataItem metadata_items = 7 [(.Ydb.size) = { ... }
*/
public java.util.List extends tech.ydb.proto.topic.YdbTopic.MetadataItemOrBuilder>
getMetadataItemsOrBuilderList() {
if (metadataItemsBuilder_ != null) {
return metadataItemsBuilder_.getMessageOrBuilderList();
} else {
return java.util.Collections.unmodifiableList(metadataItems_);
}
}
/**
*
* Message metadata. Overall size is limited to 4096 symbols (all keys and values combined).
*
*
* repeated .Ydb.Topic.MetadataItem metadata_items = 7 [(.Ydb.size) = { ... }
*/
public tech.ydb.proto.topic.YdbTopic.MetadataItem.Builder addMetadataItemsBuilder() {
return getMetadataItemsFieldBuilder().addBuilder(
tech.ydb.proto.topic.YdbTopic.MetadataItem.getDefaultInstance());
}
/**
*
* Message metadata. Overall size is limited to 4096 symbols (all keys and values combined).
*
*
* repeated .Ydb.Topic.MetadataItem metadata_items = 7 [(.Ydb.size) = { ... }
*/
public tech.ydb.proto.topic.YdbTopic.MetadataItem.Builder addMetadataItemsBuilder(
int index) {
return getMetadataItemsFieldBuilder().addBuilder(
index, tech.ydb.proto.topic.YdbTopic.MetadataItem.getDefaultInstance());
}
/**
*
* Message metadata. Overall size is limited to 4096 symbols (all keys and values combined).
*
*
* repeated .Ydb.Topic.MetadataItem metadata_items = 7 [(.Ydb.size) = { ... }
*/
public java.util.List
getMetadataItemsBuilderList() {
return getMetadataItemsFieldBuilder().getBuilderList();
}
private com.google.protobuf.RepeatedFieldBuilderV3<
tech.ydb.proto.topic.YdbTopic.MetadataItem, tech.ydb.proto.topic.YdbTopic.MetadataItem.Builder, tech.ydb.proto.topic.YdbTopic.MetadataItemOrBuilder>
getMetadataItemsFieldBuilder() {
if (metadataItemsBuilder_ == null) {
metadataItemsBuilder_ = new com.google.protobuf.RepeatedFieldBuilderV3<
tech.ydb.proto.topic.YdbTopic.MetadataItem, tech.ydb.proto.topic.YdbTopic.MetadataItem.Builder, tech.ydb.proto.topic.YdbTopic.MetadataItemOrBuilder>(
metadataItems_,
((bitField0_ & 0x00000080) != 0),
getParentForChildren(),
isClean());
metadataItems_ = null;
}
return metadataItemsBuilder_;
}
@java.lang.Override
public final Builder setUnknownFields(
final com.google.protobuf.UnknownFieldSet unknownFields) {
return super.setUnknownFields(unknownFields);
}
@java.lang.Override
public final Builder mergeUnknownFields(
final com.google.protobuf.UnknownFieldSet unknownFields) {
return super.mergeUnknownFields(unknownFields);
}
// @@protoc_insertion_point(builder_scope:Ydb.Topic.StreamWriteMessage.WriteRequest.MessageData)
}
// @@protoc_insertion_point(class_scope:Ydb.Topic.StreamWriteMessage.WriteRequest.MessageData)
private static final tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest.MessageData DEFAULT_INSTANCE;
static {
DEFAULT_INSTANCE = new tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest.MessageData();
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest.MessageData getDefaultInstance() {
return DEFAULT_INSTANCE;
}
private static final com.google.protobuf.Parser
PARSER = new com.google.protobuf.AbstractParser() {
@java.lang.Override
public MessageData parsePartialFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
Builder builder = newBuilder();
try {
builder.mergeFrom(input, extensionRegistry);
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.setUnfinishedMessage(builder.buildPartial());
} catch (com.google.protobuf.UninitializedMessageException e) {
throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial());
} catch (java.io.IOException e) {
throw new com.google.protobuf.InvalidProtocolBufferException(e)
.setUnfinishedMessage(builder.buildPartial());
}
return builder.buildPartial();
}
};
public static com.google.protobuf.Parser parser() {
return PARSER;
}
@java.lang.Override
public com.google.protobuf.Parser getParserForType() {
return PARSER;
}
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest.MessageData getDefaultInstanceForType() {
return DEFAULT_INSTANCE;
}
}
private int bitField0_;
public static final int MESSAGES_FIELD_NUMBER = 1;
@SuppressWarnings("serial")
private java.util.List messages_;
/**
* repeated .Ydb.Topic.StreamWriteMessage.WriteRequest.MessageData messages = 1;
*/
@java.lang.Override
public java.util.List getMessagesList() {
return messages_;
}
/**
* repeated .Ydb.Topic.StreamWriteMessage.WriteRequest.MessageData messages = 1;
*/
@java.lang.Override
public java.util.List extends tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest.MessageDataOrBuilder>
getMessagesOrBuilderList() {
return messages_;
}
/**
* repeated .Ydb.Topic.StreamWriteMessage.WriteRequest.MessageData messages = 1;
*/
@java.lang.Override
public int getMessagesCount() {
return messages_.size();
}
/**
* repeated .Ydb.Topic.StreamWriteMessage.WriteRequest.MessageData messages = 1;
*/
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest.MessageData getMessages(int index) {
return messages_.get(index);
}
/**
* repeated .Ydb.Topic.StreamWriteMessage.WriteRequest.MessageData messages = 1;
*/
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest.MessageDataOrBuilder getMessagesOrBuilder(
int index) {
return messages_.get(index);
}
public static final int CODEC_FIELD_NUMBER = 2;
private int codec_ = 0;
/**
*
* Codec that is used for data compression.
* See enum Codec above for values.
*
*
* int32 codec = 2;
* @return The codec.
*/
@java.lang.Override
public int getCodec() {
return codec_;
}
public static final int TX_FIELD_NUMBER = 3;
private tech.ydb.proto.topic.YdbTopic.TransactionIdentity tx_;
/**
* optional .Ydb.Topic.TransactionIdentity tx = 3;
* @return Whether the tx field is set.
*/
@java.lang.Override
public boolean hasTx() {
return ((bitField0_ & 0x00000001) != 0);
}
/**
* optional .Ydb.Topic.TransactionIdentity tx = 3;
* @return The tx.
*/
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.TransactionIdentity getTx() {
return tx_ == null ? tech.ydb.proto.topic.YdbTopic.TransactionIdentity.getDefaultInstance() : tx_;
}
/**
* optional .Ydb.Topic.TransactionIdentity tx = 3;
*/
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.TransactionIdentityOrBuilder getTxOrBuilder() {
return tx_ == null ? tech.ydb.proto.topic.YdbTopic.TransactionIdentity.getDefaultInstance() : tx_;
}
private byte memoizedIsInitialized = -1;
@java.lang.Override
public final boolean isInitialized() {
byte isInitialized = memoizedIsInitialized;
if (isInitialized == 1) return true;
if (isInitialized == 0) return false;
memoizedIsInitialized = 1;
return true;
}
@java.lang.Override
public void writeTo(com.google.protobuf.CodedOutputStream output)
throws java.io.IOException {
for (int i = 0; i < messages_.size(); i++) {
output.writeMessage(1, messages_.get(i));
}
if (codec_ != 0) {
output.writeInt32(2, codec_);
}
if (((bitField0_ & 0x00000001) != 0)) {
output.writeMessage(3, getTx());
}
getUnknownFields().writeTo(output);
}
@java.lang.Override
public int getSerializedSize() {
int size = memoizedSize;
if (size != -1) return size;
size = 0;
for (int i = 0; i < messages_.size(); i++) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(1, messages_.get(i));
}
if (codec_ != 0) {
size += com.google.protobuf.CodedOutputStream
.computeInt32Size(2, codec_);
}
if (((bitField0_ & 0x00000001) != 0)) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(3, getTx());
}
size += getUnknownFields().getSerializedSize();
memoizedSize = size;
return size;
}
@java.lang.Override
public boolean equals(final java.lang.Object obj) {
if (obj == this) {
return true;
}
if (!(obj instanceof tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest)) {
return super.equals(obj);
}
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest other = (tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest) obj;
if (!getMessagesList()
.equals(other.getMessagesList())) return false;
if (getCodec()
!= other.getCodec()) return false;
if (hasTx() != other.hasTx()) return false;
if (hasTx()) {
if (!getTx()
.equals(other.getTx())) return false;
}
if (!getUnknownFields().equals(other.getUnknownFields())) return false;
return true;
}
@java.lang.Override
public int hashCode() {
if (memoizedHashCode != 0) {
return memoizedHashCode;
}
int hash = 41;
hash = (19 * hash) + getDescriptor().hashCode();
if (getMessagesCount() > 0) {
hash = (37 * hash) + MESSAGES_FIELD_NUMBER;
hash = (53 * hash) + getMessagesList().hashCode();
}
hash = (37 * hash) + CODEC_FIELD_NUMBER;
hash = (53 * hash) + getCodec();
if (hasTx()) {
hash = (37 * hash) + TX_FIELD_NUMBER;
hash = (53 * hash) + getTx().hashCode();
}
hash = (29 * hash) + getUnknownFields().hashCode();
memoizedHashCode = hash;
return hash;
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest parseFrom(
java.nio.ByteBuffer data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest parseFrom(
java.nio.ByteBuffer data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest parseFrom(
com.google.protobuf.ByteString data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest parseFrom(
com.google.protobuf.ByteString data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest parseFrom(byte[] data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest parseFrom(
byte[] data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest parseFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest parseFrom(
java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest parseDelimitedFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input);
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest parseDelimitedFrom(
java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest parseFrom(
com.google.protobuf.CodedInputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest parseFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry);
}
@java.lang.Override
public Builder newBuilderForType() { return newBuilder(); }
public static Builder newBuilder() {
return DEFAULT_INSTANCE.toBuilder();
}
public static Builder newBuilder(tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest prototype) {
return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
}
@java.lang.Override
public Builder toBuilder() {
return this == DEFAULT_INSTANCE
? new Builder() : new Builder().mergeFrom(this);
}
@java.lang.Override
protected Builder newBuilderForType(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
Builder builder = new Builder(parent);
return builder;
}
/**
*
* Represents portion of client messages.
*
*
* Protobuf type {@code Ydb.Topic.StreamWriteMessage.WriteRequest}
*/
public static final class Builder extends
com.google.protobuf.GeneratedMessageV3.Builder implements
// @@protoc_insertion_point(builder_implements:Ydb.Topic.StreamWriteMessage.WriteRequest)
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequestOrBuilder {
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_StreamWriteMessage_WriteRequest_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_StreamWriteMessage_WriteRequest_fieldAccessorTable
.ensureFieldAccessorsInitialized(
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest.class, tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest.Builder.class);
}
// Construct using tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest.newBuilder()
private Builder() {
maybeForceBuilderInitialization();
}
private Builder(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
super(parent);
maybeForceBuilderInitialization();
}
private void maybeForceBuilderInitialization() {
if (com.google.protobuf.GeneratedMessageV3
.alwaysUseFieldBuilders) {
getMessagesFieldBuilder();
getTxFieldBuilder();
}
}
@java.lang.Override
public Builder clear() {
super.clear();
bitField0_ = 0;
if (messagesBuilder_ == null) {
messages_ = java.util.Collections.emptyList();
} else {
messages_ = null;
messagesBuilder_.clear();
}
bitField0_ = (bitField0_ & ~0x00000001);
codec_ = 0;
tx_ = null;
if (txBuilder_ != null) {
txBuilder_.dispose();
txBuilder_ = null;
}
return this;
}
@java.lang.Override
public com.google.protobuf.Descriptors.Descriptor
getDescriptorForType() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_StreamWriteMessage_WriteRequest_descriptor;
}
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest getDefaultInstanceForType() {
return tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest.getDefaultInstance();
}
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest build() {
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest result = buildPartial();
if (!result.isInitialized()) {
throw newUninitializedMessageException(result);
}
return result;
}
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest buildPartial() {
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest result = new tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest(this);
buildPartialRepeatedFields(result);
if (bitField0_ != 0) { buildPartial0(result); }
onBuilt();
return result;
}
private void buildPartialRepeatedFields(tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest result) {
if (messagesBuilder_ == null) {
if (((bitField0_ & 0x00000001) != 0)) {
messages_ = java.util.Collections.unmodifiableList(messages_);
bitField0_ = (bitField0_ & ~0x00000001);
}
result.messages_ = messages_;
} else {
result.messages_ = messagesBuilder_.build();
}
}
private void buildPartial0(tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest result) {
int from_bitField0_ = bitField0_;
if (((from_bitField0_ & 0x00000002) != 0)) {
result.codec_ = codec_;
}
int to_bitField0_ = 0;
if (((from_bitField0_ & 0x00000004) != 0)) {
result.tx_ = txBuilder_ == null
? tx_
: txBuilder_.build();
to_bitField0_ |= 0x00000001;
}
result.bitField0_ |= to_bitField0_;
}
@java.lang.Override
public Builder clone() {
return super.clone();
}
@java.lang.Override
public Builder setField(
com.google.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) {
return super.setField(field, value);
}
@java.lang.Override
public Builder clearField(
com.google.protobuf.Descriptors.FieldDescriptor field) {
return super.clearField(field);
}
@java.lang.Override
public Builder clearOneof(
com.google.protobuf.Descriptors.OneofDescriptor oneof) {
return super.clearOneof(oneof);
}
@java.lang.Override
public Builder setRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
int index, java.lang.Object value) {
return super.setRepeatedField(field, index, value);
}
@java.lang.Override
public Builder addRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) {
return super.addRepeatedField(field, value);
}
@java.lang.Override
public Builder mergeFrom(com.google.protobuf.Message other) {
if (other instanceof tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest) {
return mergeFrom((tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest)other);
} else {
super.mergeFrom(other);
return this;
}
}
public Builder mergeFrom(tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest other) {
if (other == tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest.getDefaultInstance()) return this;
if (messagesBuilder_ == null) {
if (!other.messages_.isEmpty()) {
if (messages_.isEmpty()) {
messages_ = other.messages_;
bitField0_ = (bitField0_ & ~0x00000001);
} else {
ensureMessagesIsMutable();
messages_.addAll(other.messages_);
}
onChanged();
}
} else {
if (!other.messages_.isEmpty()) {
if (messagesBuilder_.isEmpty()) {
messagesBuilder_.dispose();
messagesBuilder_ = null;
messages_ = other.messages_;
bitField0_ = (bitField0_ & ~0x00000001);
messagesBuilder_ =
com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders ?
getMessagesFieldBuilder() : null;
} else {
messagesBuilder_.addAllMessages(other.messages_);
}
}
}
if (other.getCodec() != 0) {
setCodec(other.getCodec());
}
if (other.hasTx()) {
mergeTx(other.getTx());
}
this.mergeUnknownFields(other.getUnknownFields());
onChanged();
return this;
}
@java.lang.Override
public final boolean isInitialized() {
return true;
}
@java.lang.Override
public Builder mergeFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
if (extensionRegistry == null) {
throw new java.lang.NullPointerException();
}
try {
boolean done = false;
while (!done) {
int tag = input.readTag();
switch (tag) {
case 0:
done = true;
break;
case 10: {
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest.MessageData m =
input.readMessage(
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest.MessageData.parser(),
extensionRegistry);
if (messagesBuilder_ == null) {
ensureMessagesIsMutable();
messages_.add(m);
} else {
messagesBuilder_.addMessage(m);
}
break;
} // case 10
case 16: {
codec_ = input.readInt32();
bitField0_ |= 0x00000002;
break;
} // case 16
case 26: {
input.readMessage(
getTxFieldBuilder().getBuilder(),
extensionRegistry);
bitField0_ |= 0x00000004;
break;
} // case 26
default: {
if (!super.parseUnknownField(input, extensionRegistry, tag)) {
done = true; // was an endgroup tag
}
break;
} // default:
} // switch (tag)
} // while (!done)
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.unwrapIOException();
} finally {
onChanged();
} // finally
return this;
}
private int bitField0_;
private java.util.List messages_ =
java.util.Collections.emptyList();
private void ensureMessagesIsMutable() {
if (!((bitField0_ & 0x00000001) != 0)) {
messages_ = new java.util.ArrayList(messages_);
bitField0_ |= 0x00000001;
}
}
private com.google.protobuf.RepeatedFieldBuilderV3<
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest.MessageData, tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest.MessageData.Builder, tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest.MessageDataOrBuilder> messagesBuilder_;
/**
* repeated .Ydb.Topic.StreamWriteMessage.WriteRequest.MessageData messages = 1;
*/
public java.util.List getMessagesList() {
if (messagesBuilder_ == null) {
return java.util.Collections.unmodifiableList(messages_);
} else {
return messagesBuilder_.getMessageList();
}
}
/**
* repeated .Ydb.Topic.StreamWriteMessage.WriteRequest.MessageData messages = 1;
*/
public int getMessagesCount() {
if (messagesBuilder_ == null) {
return messages_.size();
} else {
return messagesBuilder_.getCount();
}
}
/**
* repeated .Ydb.Topic.StreamWriteMessage.WriteRequest.MessageData messages = 1;
*/
public tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest.MessageData getMessages(int index) {
if (messagesBuilder_ == null) {
return messages_.get(index);
} else {
return messagesBuilder_.getMessage(index);
}
}
/**
* repeated .Ydb.Topic.StreamWriteMessage.WriteRequest.MessageData messages = 1;
*/
public Builder setMessages(
int index, tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest.MessageData value) {
if (messagesBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
ensureMessagesIsMutable();
messages_.set(index, value);
onChanged();
} else {
messagesBuilder_.setMessage(index, value);
}
return this;
}
/**
* repeated .Ydb.Topic.StreamWriteMessage.WriteRequest.MessageData messages = 1;
*/
public Builder setMessages(
int index, tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest.MessageData.Builder builderForValue) {
if (messagesBuilder_ == null) {
ensureMessagesIsMutable();
messages_.set(index, builderForValue.build());
onChanged();
} else {
messagesBuilder_.setMessage(index, builderForValue.build());
}
return this;
}
/**
* repeated .Ydb.Topic.StreamWriteMessage.WriteRequest.MessageData messages = 1;
*/
public Builder addMessages(tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest.MessageData value) {
if (messagesBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
ensureMessagesIsMutable();
messages_.add(value);
onChanged();
} else {
messagesBuilder_.addMessage(value);
}
return this;
}
/**
* repeated .Ydb.Topic.StreamWriteMessage.WriteRequest.MessageData messages = 1;
*/
public Builder addMessages(
int index, tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest.MessageData value) {
if (messagesBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
ensureMessagesIsMutable();
messages_.add(index, value);
onChanged();
} else {
messagesBuilder_.addMessage(index, value);
}
return this;
}
/**
* repeated .Ydb.Topic.StreamWriteMessage.WriteRequest.MessageData messages = 1;
*/
public Builder addMessages(
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest.MessageData.Builder builderForValue) {
if (messagesBuilder_ == null) {
ensureMessagesIsMutable();
messages_.add(builderForValue.build());
onChanged();
} else {
messagesBuilder_.addMessage(builderForValue.build());
}
return this;
}
/**
* repeated .Ydb.Topic.StreamWriteMessage.WriteRequest.MessageData messages = 1;
*/
public Builder addMessages(
int index, tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest.MessageData.Builder builderForValue) {
if (messagesBuilder_ == null) {
ensureMessagesIsMutable();
messages_.add(index, builderForValue.build());
onChanged();
} else {
messagesBuilder_.addMessage(index, builderForValue.build());
}
return this;
}
/**
* repeated .Ydb.Topic.StreamWriteMessage.WriteRequest.MessageData messages = 1;
*/
public Builder addAllMessages(
java.lang.Iterable extends tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest.MessageData> values) {
if (messagesBuilder_ == null) {
ensureMessagesIsMutable();
com.google.protobuf.AbstractMessageLite.Builder.addAll(
values, messages_);
onChanged();
} else {
messagesBuilder_.addAllMessages(values);
}
return this;
}
/**
* repeated .Ydb.Topic.StreamWriteMessage.WriteRequest.MessageData messages = 1;
*/
public Builder clearMessages() {
if (messagesBuilder_ == null) {
messages_ = java.util.Collections.emptyList();
bitField0_ = (bitField0_ & ~0x00000001);
onChanged();
} else {
messagesBuilder_.clear();
}
return this;
}
/**
* repeated .Ydb.Topic.StreamWriteMessage.WriteRequest.MessageData messages = 1;
*/
public Builder removeMessages(int index) {
if (messagesBuilder_ == null) {
ensureMessagesIsMutable();
messages_.remove(index);
onChanged();
} else {
messagesBuilder_.remove(index);
}
return this;
}
/**
* repeated .Ydb.Topic.StreamWriteMessage.WriteRequest.MessageData messages = 1;
*/
public tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest.MessageData.Builder getMessagesBuilder(
int index) {
return getMessagesFieldBuilder().getBuilder(index);
}
/**
* repeated .Ydb.Topic.StreamWriteMessage.WriteRequest.MessageData messages = 1;
*/
public tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest.MessageDataOrBuilder getMessagesOrBuilder(
int index) {
if (messagesBuilder_ == null) {
return messages_.get(index); } else {
return messagesBuilder_.getMessageOrBuilder(index);
}
}
/**
* repeated .Ydb.Topic.StreamWriteMessage.WriteRequest.MessageData messages = 1;
*/
public java.util.List extends tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest.MessageDataOrBuilder>
getMessagesOrBuilderList() {
if (messagesBuilder_ != null) {
return messagesBuilder_.getMessageOrBuilderList();
} else {
return java.util.Collections.unmodifiableList(messages_);
}
}
/**
* repeated .Ydb.Topic.StreamWriteMessage.WriteRequest.MessageData messages = 1;
*/
public tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest.MessageData.Builder addMessagesBuilder() {
return getMessagesFieldBuilder().addBuilder(
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest.MessageData.getDefaultInstance());
}
/**
* repeated .Ydb.Topic.StreamWriteMessage.WriteRequest.MessageData messages = 1;
*/
public tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest.MessageData.Builder addMessagesBuilder(
int index) {
return getMessagesFieldBuilder().addBuilder(
index, tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest.MessageData.getDefaultInstance());
}
/**
* repeated .Ydb.Topic.StreamWriteMessage.WriteRequest.MessageData messages = 1;
*/
public java.util.List
getMessagesBuilderList() {
return getMessagesFieldBuilder().getBuilderList();
}
private com.google.protobuf.RepeatedFieldBuilderV3<
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest.MessageData, tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest.MessageData.Builder, tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest.MessageDataOrBuilder>
getMessagesFieldBuilder() {
if (messagesBuilder_ == null) {
messagesBuilder_ = new com.google.protobuf.RepeatedFieldBuilderV3<
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest.MessageData, tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest.MessageData.Builder, tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest.MessageDataOrBuilder>(
messages_,
((bitField0_ & 0x00000001) != 0),
getParentForChildren(),
isClean());
messages_ = null;
}
return messagesBuilder_;
}
private int codec_ ;
/**
*
* Codec that is used for data compression.
* See enum Codec above for values.
*
*
* int32 codec = 2;
* @return The codec.
*/
@java.lang.Override
public int getCodec() {
return codec_;
}
/**
*
* Codec that is used for data compression.
* See enum Codec above for values.
*
*
* int32 codec = 2;
* @param value The codec to set.
* @return This builder for chaining.
*/
public Builder setCodec(int value) {
codec_ = value;
bitField0_ |= 0x00000002;
onChanged();
return this;
}
/**
*
* Codec that is used for data compression.
* See enum Codec above for values.
*
*
* int32 codec = 2;
* @return This builder for chaining.
*/
public Builder clearCodec() {
bitField0_ = (bitField0_ & ~0x00000002);
codec_ = 0;
onChanged();
return this;
}
private tech.ydb.proto.topic.YdbTopic.TransactionIdentity tx_;
private com.google.protobuf.SingleFieldBuilderV3<
tech.ydb.proto.topic.YdbTopic.TransactionIdentity, tech.ydb.proto.topic.YdbTopic.TransactionIdentity.Builder, tech.ydb.proto.topic.YdbTopic.TransactionIdentityOrBuilder> txBuilder_;
/**
* optional .Ydb.Topic.TransactionIdentity tx = 3;
* @return Whether the tx field is set.
*/
public boolean hasTx() {
return ((bitField0_ & 0x00000004) != 0);
}
/**
* optional .Ydb.Topic.TransactionIdentity tx = 3;
* @return The tx.
*/
public tech.ydb.proto.topic.YdbTopic.TransactionIdentity getTx() {
if (txBuilder_ == null) {
return tx_ == null ? tech.ydb.proto.topic.YdbTopic.TransactionIdentity.getDefaultInstance() : tx_;
} else {
return txBuilder_.getMessage();
}
}
/**
* optional .Ydb.Topic.TransactionIdentity tx = 3;
*/
public Builder setTx(tech.ydb.proto.topic.YdbTopic.TransactionIdentity value) {
if (txBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
tx_ = value;
} else {
txBuilder_.setMessage(value);
}
bitField0_ |= 0x00000004;
onChanged();
return this;
}
/**
* optional .Ydb.Topic.TransactionIdentity tx = 3;
*/
public Builder setTx(
tech.ydb.proto.topic.YdbTopic.TransactionIdentity.Builder builderForValue) {
if (txBuilder_ == null) {
tx_ = builderForValue.build();
} else {
txBuilder_.setMessage(builderForValue.build());
}
bitField0_ |= 0x00000004;
onChanged();
return this;
}
/**
* optional .Ydb.Topic.TransactionIdentity tx = 3;
*/
public Builder mergeTx(tech.ydb.proto.topic.YdbTopic.TransactionIdentity value) {
if (txBuilder_ == null) {
if (((bitField0_ & 0x00000004) != 0) &&
tx_ != null &&
tx_ != tech.ydb.proto.topic.YdbTopic.TransactionIdentity.getDefaultInstance()) {
getTxBuilder().mergeFrom(value);
} else {
tx_ = value;
}
} else {
txBuilder_.mergeFrom(value);
}
if (tx_ != null) {
bitField0_ |= 0x00000004;
onChanged();
}
return this;
}
/**
* optional .Ydb.Topic.TransactionIdentity tx = 3;
*/
public Builder clearTx() {
bitField0_ = (bitField0_ & ~0x00000004);
tx_ = null;
if (txBuilder_ != null) {
txBuilder_.dispose();
txBuilder_ = null;
}
onChanged();
return this;
}
/**
* optional .Ydb.Topic.TransactionIdentity tx = 3;
*/
public tech.ydb.proto.topic.YdbTopic.TransactionIdentity.Builder getTxBuilder() {
bitField0_ |= 0x00000004;
onChanged();
return getTxFieldBuilder().getBuilder();
}
/**
* optional .Ydb.Topic.TransactionIdentity tx = 3;
*/
public tech.ydb.proto.topic.YdbTopic.TransactionIdentityOrBuilder getTxOrBuilder() {
if (txBuilder_ != null) {
return txBuilder_.getMessageOrBuilder();
} else {
return tx_ == null ?
tech.ydb.proto.topic.YdbTopic.TransactionIdentity.getDefaultInstance() : tx_;
}
}
/**
* optional .Ydb.Topic.TransactionIdentity tx = 3;
*/
private com.google.protobuf.SingleFieldBuilderV3<
tech.ydb.proto.topic.YdbTopic.TransactionIdentity, tech.ydb.proto.topic.YdbTopic.TransactionIdentity.Builder, tech.ydb.proto.topic.YdbTopic.TransactionIdentityOrBuilder>
getTxFieldBuilder() {
if (txBuilder_ == null) {
txBuilder_ = new com.google.protobuf.SingleFieldBuilderV3<
tech.ydb.proto.topic.YdbTopic.TransactionIdentity, tech.ydb.proto.topic.YdbTopic.TransactionIdentity.Builder, tech.ydb.proto.topic.YdbTopic.TransactionIdentityOrBuilder>(
getTx(),
getParentForChildren(),
isClean());
tx_ = null;
}
return txBuilder_;
}
@java.lang.Override
public final Builder setUnknownFields(
final com.google.protobuf.UnknownFieldSet unknownFields) {
return super.setUnknownFields(unknownFields);
}
@java.lang.Override
public final Builder mergeUnknownFields(
final com.google.protobuf.UnknownFieldSet unknownFields) {
return super.mergeUnknownFields(unknownFields);
}
// @@protoc_insertion_point(builder_scope:Ydb.Topic.StreamWriteMessage.WriteRequest)
}
// @@protoc_insertion_point(class_scope:Ydb.Topic.StreamWriteMessage.WriteRequest)
private static final tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest DEFAULT_INSTANCE;
static {
DEFAULT_INSTANCE = new tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest();
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest getDefaultInstance() {
return DEFAULT_INSTANCE;
}
private static final com.google.protobuf.Parser
PARSER = new com.google.protobuf.AbstractParser() {
@java.lang.Override
public WriteRequest parsePartialFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
Builder builder = newBuilder();
try {
builder.mergeFrom(input, extensionRegistry);
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.setUnfinishedMessage(builder.buildPartial());
} catch (com.google.protobuf.UninitializedMessageException e) {
throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial());
} catch (java.io.IOException e) {
throw new com.google.protobuf.InvalidProtocolBufferException(e)
.setUnfinishedMessage(builder.buildPartial());
}
return builder.buildPartial();
}
};
public static com.google.protobuf.Parser parser() {
return PARSER;
}
@java.lang.Override
public com.google.protobuf.Parser getParserForType() {
return PARSER;
}
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteRequest getDefaultInstanceForType() {
return DEFAULT_INSTANCE;
}
}
public interface WriteResponseOrBuilder extends
// @@protoc_insertion_point(interface_extends:Ydb.Topic.StreamWriteMessage.WriteResponse)
com.google.protobuf.MessageOrBuilder {
/**
*
* Number of acks is equal to number of messages in the corresponding WriteRequests.
*
*
* repeated .Ydb.Topic.StreamWriteMessage.WriteResponse.WriteAck acks = 1;
*/
java.util.List
getAcksList();
/**
*
* Number of acks is equal to number of messages in the corresponding WriteRequests.
*
*
* repeated .Ydb.Topic.StreamWriteMessage.WriteResponse.WriteAck acks = 1;
*/
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck getAcks(int index);
/**
*
* Number of acks is equal to number of messages in the corresponding WriteRequests.
*
*
* repeated .Ydb.Topic.StreamWriteMessage.WriteResponse.WriteAck acks = 1;
*/
int getAcksCount();
/**
*
* Number of acks is equal to number of messages in the corresponding WriteRequests.
*
*
* repeated .Ydb.Topic.StreamWriteMessage.WriteResponse.WriteAck acks = 1;
*/
java.util.List extends tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAckOrBuilder>
getAcksOrBuilderList();
/**
*
* Number of acks is equal to number of messages in the corresponding WriteRequests.
*
*
* repeated .Ydb.Topic.StreamWriteMessage.WriteResponse.WriteAck acks = 1;
*/
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAckOrBuilder getAcksOrBuilder(
int index);
/**
*
* Assigned partition for all client messages inside this batch.
* This actual partition may differ from that returned in InitResponse
* or other WriteResponses in this write session.
*
*
* int64 partition_id = 2;
* @return The partitionId.
*/
long getPartitionId();
/**
*
* Write statistics for this sequence of client messages.
*
*
* .Ydb.Topic.StreamWriteMessage.WriteResponse.WriteStatistics write_statistics = 3;
* @return Whether the writeStatistics field is set.
*/
boolean hasWriteStatistics();
/**
*
* Write statistics for this sequence of client messages.
*
*
* .Ydb.Topic.StreamWriteMessage.WriteResponse.WriteStatistics write_statistics = 3;
* @return The writeStatistics.
*/
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteStatistics getWriteStatistics();
/**
*
* Write statistics for this sequence of client messages.
*
*
* .Ydb.Topic.StreamWriteMessage.WriteResponse.WriteStatistics write_statistics = 3;
*/
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteStatisticsOrBuilder getWriteStatisticsOrBuilder();
}
/**
*
* Message that represents acknowledgment for sequence of client messages.
* This sequence is persisted together so write statistics is for messages batch.
*
*
* Protobuf type {@code Ydb.Topic.StreamWriteMessage.WriteResponse}
*/
public static final class WriteResponse extends
com.google.protobuf.GeneratedMessageV3 implements
// @@protoc_insertion_point(message_implements:Ydb.Topic.StreamWriteMessage.WriteResponse)
WriteResponseOrBuilder {
private static final long serialVersionUID = 0L;
// Use WriteResponse.newBuilder() to construct.
private WriteResponse(com.google.protobuf.GeneratedMessageV3.Builder> builder) {
super(builder);
}
private WriteResponse() {
acks_ = java.util.Collections.emptyList();
}
@java.lang.Override
@SuppressWarnings({"unused"})
protected java.lang.Object newInstance(
UnusedPrivateParameter unused) {
return new WriteResponse();
}
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_StreamWriteMessage_WriteResponse_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_StreamWriteMessage_WriteResponse_fieldAccessorTable
.ensureFieldAccessorsInitialized(
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.class, tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.Builder.class);
}
public interface WriteAckOrBuilder extends
// @@protoc_insertion_point(interface_extends:Ydb.Topic.StreamWriteMessage.WriteResponse.WriteAck)
com.google.protobuf.MessageOrBuilder {
/**
*
* Sequence number as in WriteRequest.
*
*
* int64 seq_no = 1;
* @return The seqNo.
*/
long getSeqNo();
/**
* .Ydb.Topic.StreamWriteMessage.WriteResponse.WriteAck.Written written = 2;
* @return Whether the written field is set.
*/
boolean hasWritten();
/**
* .Ydb.Topic.StreamWriteMessage.WriteResponse.WriteAck.Written written = 2;
* @return The written.
*/
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Written getWritten();
/**
* .Ydb.Topic.StreamWriteMessage.WriteResponse.WriteAck.Written written = 2;
*/
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.WrittenOrBuilder getWrittenOrBuilder();
/**
* .Ydb.Topic.StreamWriteMessage.WriteResponse.WriteAck.Skipped skipped = 3;
* @return Whether the skipped field is set.
*/
boolean hasSkipped();
/**
* .Ydb.Topic.StreamWriteMessage.WriteResponse.WriteAck.Skipped skipped = 3;
* @return The skipped.
*/
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Skipped getSkipped();
/**
* .Ydb.Topic.StreamWriteMessage.WriteResponse.WriteAck.Skipped skipped = 3;
*/
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.SkippedOrBuilder getSkippedOrBuilder();
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.MessageWriteStatusCase getMessageWriteStatusCase();
}
/**
*
* Acknowledgment for one persistently written message.
*
*
* Protobuf type {@code Ydb.Topic.StreamWriteMessage.WriteResponse.WriteAck}
*/
public static final class WriteAck extends
com.google.protobuf.GeneratedMessageV3 implements
// @@protoc_insertion_point(message_implements:Ydb.Topic.StreamWriteMessage.WriteResponse.WriteAck)
WriteAckOrBuilder {
private static final long serialVersionUID = 0L;
// Use WriteAck.newBuilder() to construct.
private WriteAck(com.google.protobuf.GeneratedMessageV3.Builder> builder) {
super(builder);
}
private WriteAck() {
}
@java.lang.Override
@SuppressWarnings({"unused"})
protected java.lang.Object newInstance(
UnusedPrivateParameter unused) {
return new WriteAck();
}
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_StreamWriteMessage_WriteResponse_WriteAck_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_StreamWriteMessage_WriteResponse_WriteAck_fieldAccessorTable
.ensureFieldAccessorsInitialized(
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.class, tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Builder.class);
}
public interface WrittenOrBuilder extends
// @@protoc_insertion_point(interface_extends:Ydb.Topic.StreamWriteMessage.WriteResponse.WriteAck.Written)
com.google.protobuf.MessageOrBuilder {
/**
*
* Assigned partition offset.
*
*
* int64 offset = 1;
* @return The offset.
*/
long getOffset();
}
/**
* Protobuf type {@code Ydb.Topic.StreamWriteMessage.WriteResponse.WriteAck.Written}
*/
public static final class Written extends
com.google.protobuf.GeneratedMessageV3 implements
// @@protoc_insertion_point(message_implements:Ydb.Topic.StreamWriteMessage.WriteResponse.WriteAck.Written)
WrittenOrBuilder {
private static final long serialVersionUID = 0L;
// Use Written.newBuilder() to construct.
private Written(com.google.protobuf.GeneratedMessageV3.Builder> builder) {
super(builder);
}
private Written() {
}
@java.lang.Override
@SuppressWarnings({"unused"})
protected java.lang.Object newInstance(
UnusedPrivateParameter unused) {
return new Written();
}
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_StreamWriteMessage_WriteResponse_WriteAck_Written_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_StreamWriteMessage_WriteResponse_WriteAck_Written_fieldAccessorTable
.ensureFieldAccessorsInitialized(
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Written.class, tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Written.Builder.class);
}
public static final int OFFSET_FIELD_NUMBER = 1;
private long offset_ = 0L;
/**
*
* Assigned partition offset.
*
*
* int64 offset = 1;
* @return The offset.
*/
@java.lang.Override
public long getOffset() {
return offset_;
}
private byte memoizedIsInitialized = -1;
@java.lang.Override
public final boolean isInitialized() {
byte isInitialized = memoizedIsInitialized;
if (isInitialized == 1) return true;
if (isInitialized == 0) return false;
memoizedIsInitialized = 1;
return true;
}
@java.lang.Override
public void writeTo(com.google.protobuf.CodedOutputStream output)
throws java.io.IOException {
if (offset_ != 0L) {
output.writeInt64(1, offset_);
}
getUnknownFields().writeTo(output);
}
@java.lang.Override
public int getSerializedSize() {
int size = memoizedSize;
if (size != -1) return size;
size = 0;
if (offset_ != 0L) {
size += com.google.protobuf.CodedOutputStream
.computeInt64Size(1, offset_);
}
size += getUnknownFields().getSerializedSize();
memoizedSize = size;
return size;
}
@java.lang.Override
public boolean equals(final java.lang.Object obj) {
if (obj == this) {
return true;
}
if (!(obj instanceof tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Written)) {
return super.equals(obj);
}
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Written other = (tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Written) obj;
if (getOffset()
!= other.getOffset()) return false;
if (!getUnknownFields().equals(other.getUnknownFields())) return false;
return true;
}
@java.lang.Override
public int hashCode() {
if (memoizedHashCode != 0) {
return memoizedHashCode;
}
int hash = 41;
hash = (19 * hash) + getDescriptor().hashCode();
hash = (37 * hash) + OFFSET_FIELD_NUMBER;
hash = (53 * hash) + com.google.protobuf.Internal.hashLong(
getOffset());
hash = (29 * hash) + getUnknownFields().hashCode();
memoizedHashCode = hash;
return hash;
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Written parseFrom(
java.nio.ByteBuffer data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Written parseFrom(
java.nio.ByteBuffer data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Written parseFrom(
com.google.protobuf.ByteString data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Written parseFrom(
com.google.protobuf.ByteString data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Written parseFrom(byte[] data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Written parseFrom(
byte[] data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Written parseFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Written parseFrom(
java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Written parseDelimitedFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input);
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Written parseDelimitedFrom(
java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Written parseFrom(
com.google.protobuf.CodedInputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Written parseFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry);
}
@java.lang.Override
public Builder newBuilderForType() { return newBuilder(); }
public static Builder newBuilder() {
return DEFAULT_INSTANCE.toBuilder();
}
public static Builder newBuilder(tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Written prototype) {
return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
}
@java.lang.Override
public Builder toBuilder() {
return this == DEFAULT_INSTANCE
? new Builder() : new Builder().mergeFrom(this);
}
@java.lang.Override
protected Builder newBuilderForType(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
Builder builder = new Builder(parent);
return builder;
}
/**
* Protobuf type {@code Ydb.Topic.StreamWriteMessage.WriteResponse.WriteAck.Written}
*/
public static final class Builder extends
com.google.protobuf.GeneratedMessageV3.Builder implements
// @@protoc_insertion_point(builder_implements:Ydb.Topic.StreamWriteMessage.WriteResponse.WriteAck.Written)
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.WrittenOrBuilder {
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_StreamWriteMessage_WriteResponse_WriteAck_Written_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_StreamWriteMessage_WriteResponse_WriteAck_Written_fieldAccessorTable
.ensureFieldAccessorsInitialized(
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Written.class, tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Written.Builder.class);
}
// Construct using tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Written.newBuilder()
private Builder() {
}
private Builder(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
super(parent);
}
@java.lang.Override
public Builder clear() {
super.clear();
bitField0_ = 0;
offset_ = 0L;
return this;
}
@java.lang.Override
public com.google.protobuf.Descriptors.Descriptor
getDescriptorForType() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_StreamWriteMessage_WriteResponse_WriteAck_Written_descriptor;
}
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Written getDefaultInstanceForType() {
return tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Written.getDefaultInstance();
}
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Written build() {
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Written result = buildPartial();
if (!result.isInitialized()) {
throw newUninitializedMessageException(result);
}
return result;
}
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Written buildPartial() {
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Written result = new tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Written(this);
if (bitField0_ != 0) { buildPartial0(result); }
onBuilt();
return result;
}
private void buildPartial0(tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Written result) {
int from_bitField0_ = bitField0_;
if (((from_bitField0_ & 0x00000001) != 0)) {
result.offset_ = offset_;
}
}
@java.lang.Override
public Builder clone() {
return super.clone();
}
@java.lang.Override
public Builder setField(
com.google.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) {
return super.setField(field, value);
}
@java.lang.Override
public Builder clearField(
com.google.protobuf.Descriptors.FieldDescriptor field) {
return super.clearField(field);
}
@java.lang.Override
public Builder clearOneof(
com.google.protobuf.Descriptors.OneofDescriptor oneof) {
return super.clearOneof(oneof);
}
@java.lang.Override
public Builder setRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
int index, java.lang.Object value) {
return super.setRepeatedField(field, index, value);
}
@java.lang.Override
public Builder addRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) {
return super.addRepeatedField(field, value);
}
@java.lang.Override
public Builder mergeFrom(com.google.protobuf.Message other) {
if (other instanceof tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Written) {
return mergeFrom((tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Written)other);
} else {
super.mergeFrom(other);
return this;
}
}
public Builder mergeFrom(tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Written other) {
if (other == tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Written.getDefaultInstance()) return this;
if (other.getOffset() != 0L) {
setOffset(other.getOffset());
}
this.mergeUnknownFields(other.getUnknownFields());
onChanged();
return this;
}
@java.lang.Override
public final boolean isInitialized() {
return true;
}
@java.lang.Override
public Builder mergeFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
if (extensionRegistry == null) {
throw new java.lang.NullPointerException();
}
try {
boolean done = false;
while (!done) {
int tag = input.readTag();
switch (tag) {
case 0:
done = true;
break;
case 8: {
offset_ = input.readInt64();
bitField0_ |= 0x00000001;
break;
} // case 8
default: {
if (!super.parseUnknownField(input, extensionRegistry, tag)) {
done = true; // was an endgroup tag
}
break;
} // default:
} // switch (tag)
} // while (!done)
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.unwrapIOException();
} finally {
onChanged();
} // finally
return this;
}
private int bitField0_;
private long offset_ ;
/**
*
* Assigned partition offset.
*
*
* int64 offset = 1;
* @return The offset.
*/
@java.lang.Override
public long getOffset() {
return offset_;
}
/**
*
* Assigned partition offset.
*
*
* int64 offset = 1;
* @param value The offset to set.
* @return This builder for chaining.
*/
public Builder setOffset(long value) {
offset_ = value;
bitField0_ |= 0x00000001;
onChanged();
return this;
}
/**
*
* Assigned partition offset.
*
*
* int64 offset = 1;
* @return This builder for chaining.
*/
public Builder clearOffset() {
bitField0_ = (bitField0_ & ~0x00000001);
offset_ = 0L;
onChanged();
return this;
}
@java.lang.Override
public final Builder setUnknownFields(
final com.google.protobuf.UnknownFieldSet unknownFields) {
return super.setUnknownFields(unknownFields);
}
@java.lang.Override
public final Builder mergeUnknownFields(
final com.google.protobuf.UnknownFieldSet unknownFields) {
return super.mergeUnknownFields(unknownFields);
}
// @@protoc_insertion_point(builder_scope:Ydb.Topic.StreamWriteMessage.WriteResponse.WriteAck.Written)
}
// @@protoc_insertion_point(class_scope:Ydb.Topic.StreamWriteMessage.WriteResponse.WriteAck.Written)
private static final tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Written DEFAULT_INSTANCE;
static {
DEFAULT_INSTANCE = new tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Written();
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Written getDefaultInstance() {
return DEFAULT_INSTANCE;
}
private static final com.google.protobuf.Parser
PARSER = new com.google.protobuf.AbstractParser() {
@java.lang.Override
public Written parsePartialFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
Builder builder = newBuilder();
try {
builder.mergeFrom(input, extensionRegistry);
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.setUnfinishedMessage(builder.buildPartial());
} catch (com.google.protobuf.UninitializedMessageException e) {
throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial());
} catch (java.io.IOException e) {
throw new com.google.protobuf.InvalidProtocolBufferException(e)
.setUnfinishedMessage(builder.buildPartial());
}
return builder.buildPartial();
}
};
public static com.google.protobuf.Parser parser() {
return PARSER;
}
@java.lang.Override
public com.google.protobuf.Parser getParserForType() {
return PARSER;
}
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Written getDefaultInstanceForType() {
return DEFAULT_INSTANCE;
}
}
public interface SkippedOrBuilder extends
// @@protoc_insertion_point(interface_extends:Ydb.Topic.StreamWriteMessage.WriteResponse.WriteAck.Skipped)
com.google.protobuf.MessageOrBuilder {
/**
* .Ydb.Topic.StreamWriteMessage.WriteResponse.WriteAck.Skipped.Reason reason = 1;
* @return The enum numeric value on the wire for reason.
*/
int getReasonValue();
/**
* .Ydb.Topic.StreamWriteMessage.WriteResponse.WriteAck.Skipped.Reason reason = 1;
* @return The reason.
*/
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Skipped.Reason getReason();
}
/**
* Protobuf type {@code Ydb.Topic.StreamWriteMessage.WriteResponse.WriteAck.Skipped}
*/
public static final class Skipped extends
com.google.protobuf.GeneratedMessageV3 implements
// @@protoc_insertion_point(message_implements:Ydb.Topic.StreamWriteMessage.WriteResponse.WriteAck.Skipped)
SkippedOrBuilder {
private static final long serialVersionUID = 0L;
// Use Skipped.newBuilder() to construct.
private Skipped(com.google.protobuf.GeneratedMessageV3.Builder> builder) {
super(builder);
}
private Skipped() {
reason_ = 0;
}
@java.lang.Override
@SuppressWarnings({"unused"})
protected java.lang.Object newInstance(
UnusedPrivateParameter unused) {
return new Skipped();
}
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_StreamWriteMessage_WriteResponse_WriteAck_Skipped_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_StreamWriteMessage_WriteResponse_WriteAck_Skipped_fieldAccessorTable
.ensureFieldAccessorsInitialized(
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Skipped.class, tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Skipped.Builder.class);
}
/**
* Protobuf enum {@code Ydb.Topic.StreamWriteMessage.WriteResponse.WriteAck.Skipped.Reason}
*/
public enum Reason
implements com.google.protobuf.ProtocolMessageEnum {
/**
* REASON_UNSPECIFIED = 0;
*/
REASON_UNSPECIFIED(0),
/**
* REASON_ALREADY_WRITTEN = 1;
*/
REASON_ALREADY_WRITTEN(1),
UNRECOGNIZED(-1),
;
/**
* REASON_UNSPECIFIED = 0;
*/
public static final int REASON_UNSPECIFIED_VALUE = 0;
/**
* REASON_ALREADY_WRITTEN = 1;
*/
public static final int REASON_ALREADY_WRITTEN_VALUE = 1;
public final int getNumber() {
if (this == UNRECOGNIZED) {
throw new java.lang.IllegalArgumentException(
"Can't get the number of an unknown enum value.");
}
return value;
}
/**
* @param value The numeric wire value of the corresponding enum entry.
* @return The enum associated with the given numeric wire value.
* @deprecated Use {@link #forNumber(int)} instead.
*/
@java.lang.Deprecated
public static Reason valueOf(int value) {
return forNumber(value);
}
/**
* @param value The numeric wire value of the corresponding enum entry.
* @return The enum associated with the given numeric wire value.
*/
public static Reason forNumber(int value) {
switch (value) {
case 0: return REASON_UNSPECIFIED;
case 1: return REASON_ALREADY_WRITTEN;
default: return null;
}
}
public static com.google.protobuf.Internal.EnumLiteMap
internalGetValueMap() {
return internalValueMap;
}
private static final com.google.protobuf.Internal.EnumLiteMap<
Reason> internalValueMap =
new com.google.protobuf.Internal.EnumLiteMap() {
public Reason findValueByNumber(int number) {
return Reason.forNumber(number);
}
};
public final com.google.protobuf.Descriptors.EnumValueDescriptor
getValueDescriptor() {
if (this == UNRECOGNIZED) {
throw new java.lang.IllegalStateException(
"Can't get the descriptor of an unrecognized enum value.");
}
return getDescriptor().getValues().get(ordinal());
}
public final com.google.protobuf.Descriptors.EnumDescriptor
getDescriptorForType() {
return getDescriptor();
}
public static final com.google.protobuf.Descriptors.EnumDescriptor
getDescriptor() {
return tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Skipped.getDescriptor().getEnumTypes().get(0);
}
private static final Reason[] VALUES = values();
public static Reason valueOf(
com.google.protobuf.Descriptors.EnumValueDescriptor desc) {
if (desc.getType() != getDescriptor()) {
throw new java.lang.IllegalArgumentException(
"EnumValueDescriptor is not for this type.");
}
if (desc.getIndex() == -1) {
return UNRECOGNIZED;
}
return VALUES[desc.getIndex()];
}
private final int value;
private Reason(int value) {
this.value = value;
}
// @@protoc_insertion_point(enum_scope:Ydb.Topic.StreamWriteMessage.WriteResponse.WriteAck.Skipped.Reason)
}
public static final int REASON_FIELD_NUMBER = 1;
private int reason_ = 0;
/**
* .Ydb.Topic.StreamWriteMessage.WriteResponse.WriteAck.Skipped.Reason reason = 1;
* @return The enum numeric value on the wire for reason.
*/
@java.lang.Override public int getReasonValue() {
return reason_;
}
/**
* .Ydb.Topic.StreamWriteMessage.WriteResponse.WriteAck.Skipped.Reason reason = 1;
* @return The reason.
*/
@java.lang.Override public tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Skipped.Reason getReason() {
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Skipped.Reason result = tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Skipped.Reason.forNumber(reason_);
return result == null ? tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Skipped.Reason.UNRECOGNIZED : result;
}
private byte memoizedIsInitialized = -1;
@java.lang.Override
public final boolean isInitialized() {
byte isInitialized = memoizedIsInitialized;
if (isInitialized == 1) return true;
if (isInitialized == 0) return false;
memoizedIsInitialized = 1;
return true;
}
@java.lang.Override
public void writeTo(com.google.protobuf.CodedOutputStream output)
throws java.io.IOException {
if (reason_ != tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Skipped.Reason.REASON_UNSPECIFIED.getNumber()) {
output.writeEnum(1, reason_);
}
getUnknownFields().writeTo(output);
}
@java.lang.Override
public int getSerializedSize() {
int size = memoizedSize;
if (size != -1) return size;
size = 0;
if (reason_ != tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Skipped.Reason.REASON_UNSPECIFIED.getNumber()) {
size += com.google.protobuf.CodedOutputStream
.computeEnumSize(1, reason_);
}
size += getUnknownFields().getSerializedSize();
memoizedSize = size;
return size;
}
@java.lang.Override
public boolean equals(final java.lang.Object obj) {
if (obj == this) {
return true;
}
if (!(obj instanceof tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Skipped)) {
return super.equals(obj);
}
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Skipped other = (tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Skipped) obj;
if (reason_ != other.reason_) return false;
if (!getUnknownFields().equals(other.getUnknownFields())) return false;
return true;
}
@java.lang.Override
public int hashCode() {
if (memoizedHashCode != 0) {
return memoizedHashCode;
}
int hash = 41;
hash = (19 * hash) + getDescriptor().hashCode();
hash = (37 * hash) + REASON_FIELD_NUMBER;
hash = (53 * hash) + reason_;
hash = (29 * hash) + getUnknownFields().hashCode();
memoizedHashCode = hash;
return hash;
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Skipped parseFrom(
java.nio.ByteBuffer data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Skipped parseFrom(
java.nio.ByteBuffer data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Skipped parseFrom(
com.google.protobuf.ByteString data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Skipped parseFrom(
com.google.protobuf.ByteString data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Skipped parseFrom(byte[] data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Skipped parseFrom(
byte[] data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Skipped parseFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Skipped parseFrom(
java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Skipped parseDelimitedFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input);
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Skipped parseDelimitedFrom(
java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Skipped parseFrom(
com.google.protobuf.CodedInputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Skipped parseFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry);
}
@java.lang.Override
public Builder newBuilderForType() { return newBuilder(); }
public static Builder newBuilder() {
return DEFAULT_INSTANCE.toBuilder();
}
public static Builder newBuilder(tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Skipped prototype) {
return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
}
@java.lang.Override
public Builder toBuilder() {
return this == DEFAULT_INSTANCE
? new Builder() : new Builder().mergeFrom(this);
}
@java.lang.Override
protected Builder newBuilderForType(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
Builder builder = new Builder(parent);
return builder;
}
/**
* Protobuf type {@code Ydb.Topic.StreamWriteMessage.WriteResponse.WriteAck.Skipped}
*/
public static final class Builder extends
com.google.protobuf.GeneratedMessageV3.Builder implements
// @@protoc_insertion_point(builder_implements:Ydb.Topic.StreamWriteMessage.WriteResponse.WriteAck.Skipped)
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.SkippedOrBuilder {
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_StreamWriteMessage_WriteResponse_WriteAck_Skipped_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_StreamWriteMessage_WriteResponse_WriteAck_Skipped_fieldAccessorTable
.ensureFieldAccessorsInitialized(
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Skipped.class, tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Skipped.Builder.class);
}
// Construct using tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Skipped.newBuilder()
private Builder() {
}
private Builder(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
super(parent);
}
@java.lang.Override
public Builder clear() {
super.clear();
bitField0_ = 0;
reason_ = 0;
return this;
}
@java.lang.Override
public com.google.protobuf.Descriptors.Descriptor
getDescriptorForType() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_StreamWriteMessage_WriteResponse_WriteAck_Skipped_descriptor;
}
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Skipped getDefaultInstanceForType() {
return tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Skipped.getDefaultInstance();
}
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Skipped build() {
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Skipped result = buildPartial();
if (!result.isInitialized()) {
throw newUninitializedMessageException(result);
}
return result;
}
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Skipped buildPartial() {
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Skipped result = new tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Skipped(this);
if (bitField0_ != 0) { buildPartial0(result); }
onBuilt();
return result;
}
private void buildPartial0(tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Skipped result) {
int from_bitField0_ = bitField0_;
if (((from_bitField0_ & 0x00000001) != 0)) {
result.reason_ = reason_;
}
}
@java.lang.Override
public Builder clone() {
return super.clone();
}
@java.lang.Override
public Builder setField(
com.google.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) {
return super.setField(field, value);
}
@java.lang.Override
public Builder clearField(
com.google.protobuf.Descriptors.FieldDescriptor field) {
return super.clearField(field);
}
@java.lang.Override
public Builder clearOneof(
com.google.protobuf.Descriptors.OneofDescriptor oneof) {
return super.clearOneof(oneof);
}
@java.lang.Override
public Builder setRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
int index, java.lang.Object value) {
return super.setRepeatedField(field, index, value);
}
@java.lang.Override
public Builder addRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) {
return super.addRepeatedField(field, value);
}
@java.lang.Override
public Builder mergeFrom(com.google.protobuf.Message other) {
if (other instanceof tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Skipped) {
return mergeFrom((tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Skipped)other);
} else {
super.mergeFrom(other);
return this;
}
}
public Builder mergeFrom(tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Skipped other) {
if (other == tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Skipped.getDefaultInstance()) return this;
if (other.reason_ != 0) {
setReasonValue(other.getReasonValue());
}
this.mergeUnknownFields(other.getUnknownFields());
onChanged();
return this;
}
@java.lang.Override
public final boolean isInitialized() {
return true;
}
@java.lang.Override
public Builder mergeFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
if (extensionRegistry == null) {
throw new java.lang.NullPointerException();
}
try {
boolean done = false;
while (!done) {
int tag = input.readTag();
switch (tag) {
case 0:
done = true;
break;
case 8: {
reason_ = input.readEnum();
bitField0_ |= 0x00000001;
break;
} // case 8
default: {
if (!super.parseUnknownField(input, extensionRegistry, tag)) {
done = true; // was an endgroup tag
}
break;
} // default:
} // switch (tag)
} // while (!done)
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.unwrapIOException();
} finally {
onChanged();
} // finally
return this;
}
private int bitField0_;
private int reason_ = 0;
/**
* .Ydb.Topic.StreamWriteMessage.WriteResponse.WriteAck.Skipped.Reason reason = 1;
* @return The enum numeric value on the wire for reason.
*/
@java.lang.Override public int getReasonValue() {
return reason_;
}
/**
* .Ydb.Topic.StreamWriteMessage.WriteResponse.WriteAck.Skipped.Reason reason = 1;
* @param value The enum numeric value on the wire for reason to set.
* @return This builder for chaining.
*/
public Builder setReasonValue(int value) {
reason_ = value;
bitField0_ |= 0x00000001;
onChanged();
return this;
}
/**
* .Ydb.Topic.StreamWriteMessage.WriteResponse.WriteAck.Skipped.Reason reason = 1;
* @return The reason.
*/
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Skipped.Reason getReason() {
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Skipped.Reason result = tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Skipped.Reason.forNumber(reason_);
return result == null ? tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Skipped.Reason.UNRECOGNIZED : result;
}
/**
* .Ydb.Topic.StreamWriteMessage.WriteResponse.WriteAck.Skipped.Reason reason = 1;
* @param value The reason to set.
* @return This builder for chaining.
*/
public Builder setReason(tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Skipped.Reason value) {
if (value == null) {
throw new NullPointerException();
}
bitField0_ |= 0x00000001;
reason_ = value.getNumber();
onChanged();
return this;
}
/**
* .Ydb.Topic.StreamWriteMessage.WriteResponse.WriteAck.Skipped.Reason reason = 1;
* @return This builder for chaining.
*/
public Builder clearReason() {
bitField0_ = (bitField0_ & ~0x00000001);
reason_ = 0;
onChanged();
return this;
}
@java.lang.Override
public final Builder setUnknownFields(
final com.google.protobuf.UnknownFieldSet unknownFields) {
return super.setUnknownFields(unknownFields);
}
@java.lang.Override
public final Builder mergeUnknownFields(
final com.google.protobuf.UnknownFieldSet unknownFields) {
return super.mergeUnknownFields(unknownFields);
}
// @@protoc_insertion_point(builder_scope:Ydb.Topic.StreamWriteMessage.WriteResponse.WriteAck.Skipped)
}
// @@protoc_insertion_point(class_scope:Ydb.Topic.StreamWriteMessage.WriteResponse.WriteAck.Skipped)
private static final tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Skipped DEFAULT_INSTANCE;
static {
DEFAULT_INSTANCE = new tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Skipped();
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Skipped getDefaultInstance() {
return DEFAULT_INSTANCE;
}
private static final com.google.protobuf.Parser
PARSER = new com.google.protobuf.AbstractParser() {
@java.lang.Override
public Skipped parsePartialFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
Builder builder = newBuilder();
try {
builder.mergeFrom(input, extensionRegistry);
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.setUnfinishedMessage(builder.buildPartial());
} catch (com.google.protobuf.UninitializedMessageException e) {
throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial());
} catch (java.io.IOException e) {
throw new com.google.protobuf.InvalidProtocolBufferException(e)
.setUnfinishedMessage(builder.buildPartial());
}
return builder.buildPartial();
}
};
public static com.google.protobuf.Parser parser() {
return PARSER;
}
@java.lang.Override
public com.google.protobuf.Parser getParserForType() {
return PARSER;
}
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Skipped getDefaultInstanceForType() {
return DEFAULT_INSTANCE;
}
}
private int messageWriteStatusCase_ = 0;
@SuppressWarnings("serial")
private java.lang.Object messageWriteStatus_;
public enum MessageWriteStatusCase
implements com.google.protobuf.Internal.EnumLite,
com.google.protobuf.AbstractMessage.InternalOneOfEnum {
WRITTEN(2),
SKIPPED(3),
MESSAGEWRITESTATUS_NOT_SET(0);
private final int value;
private MessageWriteStatusCase(int value) {
this.value = value;
}
/**
* @param value The number of the enum to look for.
* @return The enum associated with the given number.
* @deprecated Use {@link #forNumber(int)} instead.
*/
@java.lang.Deprecated
public static MessageWriteStatusCase valueOf(int value) {
return forNumber(value);
}
public static MessageWriteStatusCase forNumber(int value) {
switch (value) {
case 2: return WRITTEN;
case 3: return SKIPPED;
case 0: return MESSAGEWRITESTATUS_NOT_SET;
default: return null;
}
}
public int getNumber() {
return this.value;
}
};
public MessageWriteStatusCase
getMessageWriteStatusCase() {
return MessageWriteStatusCase.forNumber(
messageWriteStatusCase_);
}
public static final int SEQ_NO_FIELD_NUMBER = 1;
private long seqNo_ = 0L;
/**
*
* Sequence number as in WriteRequest.
*
*
* int64 seq_no = 1;
* @return The seqNo.
*/
@java.lang.Override
public long getSeqNo() {
return seqNo_;
}
public static final int WRITTEN_FIELD_NUMBER = 2;
/**
* .Ydb.Topic.StreamWriteMessage.WriteResponse.WriteAck.Written written = 2;
* @return Whether the written field is set.
*/
@java.lang.Override
public boolean hasWritten() {
return messageWriteStatusCase_ == 2;
}
/**
* .Ydb.Topic.StreamWriteMessage.WriteResponse.WriteAck.Written written = 2;
* @return The written.
*/
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Written getWritten() {
if (messageWriteStatusCase_ == 2) {
return (tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Written) messageWriteStatus_;
}
return tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Written.getDefaultInstance();
}
/**
* .Ydb.Topic.StreamWriteMessage.WriteResponse.WriteAck.Written written = 2;
*/
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.WrittenOrBuilder getWrittenOrBuilder() {
if (messageWriteStatusCase_ == 2) {
return (tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Written) messageWriteStatus_;
}
return tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Written.getDefaultInstance();
}
public static final int SKIPPED_FIELD_NUMBER = 3;
/**
* .Ydb.Topic.StreamWriteMessage.WriteResponse.WriteAck.Skipped skipped = 3;
* @return Whether the skipped field is set.
*/
@java.lang.Override
public boolean hasSkipped() {
return messageWriteStatusCase_ == 3;
}
/**
* .Ydb.Topic.StreamWriteMessage.WriteResponse.WriteAck.Skipped skipped = 3;
* @return The skipped.
*/
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Skipped getSkipped() {
if (messageWriteStatusCase_ == 3) {
return (tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Skipped) messageWriteStatus_;
}
return tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Skipped.getDefaultInstance();
}
/**
* .Ydb.Topic.StreamWriteMessage.WriteResponse.WriteAck.Skipped skipped = 3;
*/
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.SkippedOrBuilder getSkippedOrBuilder() {
if (messageWriteStatusCase_ == 3) {
return (tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Skipped) messageWriteStatus_;
}
return tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Skipped.getDefaultInstance();
}
private byte memoizedIsInitialized = -1;
@java.lang.Override
public final boolean isInitialized() {
byte isInitialized = memoizedIsInitialized;
if (isInitialized == 1) return true;
if (isInitialized == 0) return false;
memoizedIsInitialized = 1;
return true;
}
@java.lang.Override
public void writeTo(com.google.protobuf.CodedOutputStream output)
throws java.io.IOException {
if (seqNo_ != 0L) {
output.writeInt64(1, seqNo_);
}
if (messageWriteStatusCase_ == 2) {
output.writeMessage(2, (tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Written) messageWriteStatus_);
}
if (messageWriteStatusCase_ == 3) {
output.writeMessage(3, (tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Skipped) messageWriteStatus_);
}
getUnknownFields().writeTo(output);
}
@java.lang.Override
public int getSerializedSize() {
int size = memoizedSize;
if (size != -1) return size;
size = 0;
if (seqNo_ != 0L) {
size += com.google.protobuf.CodedOutputStream
.computeInt64Size(1, seqNo_);
}
if (messageWriteStatusCase_ == 2) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(2, (tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Written) messageWriteStatus_);
}
if (messageWriteStatusCase_ == 3) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(3, (tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Skipped) messageWriteStatus_);
}
size += getUnknownFields().getSerializedSize();
memoizedSize = size;
return size;
}
@java.lang.Override
public boolean equals(final java.lang.Object obj) {
if (obj == this) {
return true;
}
if (!(obj instanceof tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck)) {
return super.equals(obj);
}
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck other = (tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck) obj;
if (getSeqNo()
!= other.getSeqNo()) return false;
if (!getMessageWriteStatusCase().equals(other.getMessageWriteStatusCase())) return false;
switch (messageWriteStatusCase_) {
case 2:
if (!getWritten()
.equals(other.getWritten())) return false;
break;
case 3:
if (!getSkipped()
.equals(other.getSkipped())) return false;
break;
case 0:
default:
}
if (!getUnknownFields().equals(other.getUnknownFields())) return false;
return true;
}
@java.lang.Override
public int hashCode() {
if (memoizedHashCode != 0) {
return memoizedHashCode;
}
int hash = 41;
hash = (19 * hash) + getDescriptor().hashCode();
hash = (37 * hash) + SEQ_NO_FIELD_NUMBER;
hash = (53 * hash) + com.google.protobuf.Internal.hashLong(
getSeqNo());
switch (messageWriteStatusCase_) {
case 2:
hash = (37 * hash) + WRITTEN_FIELD_NUMBER;
hash = (53 * hash) + getWritten().hashCode();
break;
case 3:
hash = (37 * hash) + SKIPPED_FIELD_NUMBER;
hash = (53 * hash) + getSkipped().hashCode();
break;
case 0:
default:
}
hash = (29 * hash) + getUnknownFields().hashCode();
memoizedHashCode = hash;
return hash;
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck parseFrom(
java.nio.ByteBuffer data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck parseFrom(
java.nio.ByteBuffer data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck parseFrom(
com.google.protobuf.ByteString data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck parseFrom(
com.google.protobuf.ByteString data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck parseFrom(byte[] data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck parseFrom(
byte[] data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck parseFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck parseFrom(
java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck parseDelimitedFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input);
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck parseDelimitedFrom(
java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck parseFrom(
com.google.protobuf.CodedInputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck parseFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry);
}
@java.lang.Override
public Builder newBuilderForType() { return newBuilder(); }
public static Builder newBuilder() {
return DEFAULT_INSTANCE.toBuilder();
}
public static Builder newBuilder(tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck prototype) {
return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
}
@java.lang.Override
public Builder toBuilder() {
return this == DEFAULT_INSTANCE
? new Builder() : new Builder().mergeFrom(this);
}
@java.lang.Override
protected Builder newBuilderForType(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
Builder builder = new Builder(parent);
return builder;
}
/**
*
* Acknowledgment for one persistently written message.
*
*
* Protobuf type {@code Ydb.Topic.StreamWriteMessage.WriteResponse.WriteAck}
*/
public static final class Builder extends
com.google.protobuf.GeneratedMessageV3.Builder implements
// @@protoc_insertion_point(builder_implements:Ydb.Topic.StreamWriteMessage.WriteResponse.WriteAck)
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAckOrBuilder {
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_StreamWriteMessage_WriteResponse_WriteAck_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_StreamWriteMessage_WriteResponse_WriteAck_fieldAccessorTable
.ensureFieldAccessorsInitialized(
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.class, tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Builder.class);
}
// Construct using tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.newBuilder()
private Builder() {
}
private Builder(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
super(parent);
}
@java.lang.Override
public Builder clear() {
super.clear();
bitField0_ = 0;
seqNo_ = 0L;
if (writtenBuilder_ != null) {
writtenBuilder_.clear();
}
if (skippedBuilder_ != null) {
skippedBuilder_.clear();
}
messageWriteStatusCase_ = 0;
messageWriteStatus_ = null;
return this;
}
@java.lang.Override
public com.google.protobuf.Descriptors.Descriptor
getDescriptorForType() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_StreamWriteMessage_WriteResponse_WriteAck_descriptor;
}
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck getDefaultInstanceForType() {
return tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.getDefaultInstance();
}
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck build() {
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck result = buildPartial();
if (!result.isInitialized()) {
throw newUninitializedMessageException(result);
}
return result;
}
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck buildPartial() {
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck result = new tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck(this);
if (bitField0_ != 0) { buildPartial0(result); }
buildPartialOneofs(result);
onBuilt();
return result;
}
private void buildPartial0(tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck result) {
int from_bitField0_ = bitField0_;
if (((from_bitField0_ & 0x00000001) != 0)) {
result.seqNo_ = seqNo_;
}
}
private void buildPartialOneofs(tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck result) {
result.messageWriteStatusCase_ = messageWriteStatusCase_;
result.messageWriteStatus_ = this.messageWriteStatus_;
if (messageWriteStatusCase_ == 2 &&
writtenBuilder_ != null) {
result.messageWriteStatus_ = writtenBuilder_.build();
}
if (messageWriteStatusCase_ == 3 &&
skippedBuilder_ != null) {
result.messageWriteStatus_ = skippedBuilder_.build();
}
}
@java.lang.Override
public Builder clone() {
return super.clone();
}
@java.lang.Override
public Builder setField(
com.google.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) {
return super.setField(field, value);
}
@java.lang.Override
public Builder clearField(
com.google.protobuf.Descriptors.FieldDescriptor field) {
return super.clearField(field);
}
@java.lang.Override
public Builder clearOneof(
com.google.protobuf.Descriptors.OneofDescriptor oneof) {
return super.clearOneof(oneof);
}
@java.lang.Override
public Builder setRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
int index, java.lang.Object value) {
return super.setRepeatedField(field, index, value);
}
@java.lang.Override
public Builder addRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) {
return super.addRepeatedField(field, value);
}
@java.lang.Override
public Builder mergeFrom(com.google.protobuf.Message other) {
if (other instanceof tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck) {
return mergeFrom((tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck)other);
} else {
super.mergeFrom(other);
return this;
}
}
public Builder mergeFrom(tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck other) {
if (other == tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.getDefaultInstance()) return this;
if (other.getSeqNo() != 0L) {
setSeqNo(other.getSeqNo());
}
switch (other.getMessageWriteStatusCase()) {
case WRITTEN: {
mergeWritten(other.getWritten());
break;
}
case SKIPPED: {
mergeSkipped(other.getSkipped());
break;
}
case MESSAGEWRITESTATUS_NOT_SET: {
break;
}
}
this.mergeUnknownFields(other.getUnknownFields());
onChanged();
return this;
}
@java.lang.Override
public final boolean isInitialized() {
return true;
}
@java.lang.Override
public Builder mergeFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
if (extensionRegistry == null) {
throw new java.lang.NullPointerException();
}
try {
boolean done = false;
while (!done) {
int tag = input.readTag();
switch (tag) {
case 0:
done = true;
break;
case 8: {
seqNo_ = input.readInt64();
bitField0_ |= 0x00000001;
break;
} // case 8
case 18: {
input.readMessage(
getWrittenFieldBuilder().getBuilder(),
extensionRegistry);
messageWriteStatusCase_ = 2;
break;
} // case 18
case 26: {
input.readMessage(
getSkippedFieldBuilder().getBuilder(),
extensionRegistry);
messageWriteStatusCase_ = 3;
break;
} // case 26
default: {
if (!super.parseUnknownField(input, extensionRegistry, tag)) {
done = true; // was an endgroup tag
}
break;
} // default:
} // switch (tag)
} // while (!done)
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.unwrapIOException();
} finally {
onChanged();
} // finally
return this;
}
private int messageWriteStatusCase_ = 0;
private java.lang.Object messageWriteStatus_;
public MessageWriteStatusCase
getMessageWriteStatusCase() {
return MessageWriteStatusCase.forNumber(
messageWriteStatusCase_);
}
public Builder clearMessageWriteStatus() {
messageWriteStatusCase_ = 0;
messageWriteStatus_ = null;
onChanged();
return this;
}
private int bitField0_;
private long seqNo_ ;
/**
*
* Sequence number as in WriteRequest.
*
*
* int64 seq_no = 1;
* @return The seqNo.
*/
@java.lang.Override
public long getSeqNo() {
return seqNo_;
}
/**
*
* Sequence number as in WriteRequest.
*
*
* int64 seq_no = 1;
* @param value The seqNo to set.
* @return This builder for chaining.
*/
public Builder setSeqNo(long value) {
seqNo_ = value;
bitField0_ |= 0x00000001;
onChanged();
return this;
}
/**
*
* Sequence number as in WriteRequest.
*
*
* int64 seq_no = 1;
* @return This builder for chaining.
*/
public Builder clearSeqNo() {
bitField0_ = (bitField0_ & ~0x00000001);
seqNo_ = 0L;
onChanged();
return this;
}
private com.google.protobuf.SingleFieldBuilderV3<
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Written, tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Written.Builder, tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.WrittenOrBuilder> writtenBuilder_;
/**
* .Ydb.Topic.StreamWriteMessage.WriteResponse.WriteAck.Written written = 2;
* @return Whether the written field is set.
*/
@java.lang.Override
public boolean hasWritten() {
return messageWriteStatusCase_ == 2;
}
/**
* .Ydb.Topic.StreamWriteMessage.WriteResponse.WriteAck.Written written = 2;
* @return The written.
*/
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Written getWritten() {
if (writtenBuilder_ == null) {
if (messageWriteStatusCase_ == 2) {
return (tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Written) messageWriteStatus_;
}
return tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Written.getDefaultInstance();
} else {
if (messageWriteStatusCase_ == 2) {
return writtenBuilder_.getMessage();
}
return tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Written.getDefaultInstance();
}
}
/**
* .Ydb.Topic.StreamWriteMessage.WriteResponse.WriteAck.Written written = 2;
*/
public Builder setWritten(tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Written value) {
if (writtenBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
messageWriteStatus_ = value;
onChanged();
} else {
writtenBuilder_.setMessage(value);
}
messageWriteStatusCase_ = 2;
return this;
}
/**
* .Ydb.Topic.StreamWriteMessage.WriteResponse.WriteAck.Written written = 2;
*/
public Builder setWritten(
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Written.Builder builderForValue) {
if (writtenBuilder_ == null) {
messageWriteStatus_ = builderForValue.build();
onChanged();
} else {
writtenBuilder_.setMessage(builderForValue.build());
}
messageWriteStatusCase_ = 2;
return this;
}
/**
* .Ydb.Topic.StreamWriteMessage.WriteResponse.WriteAck.Written written = 2;
*/
public Builder mergeWritten(tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Written value) {
if (writtenBuilder_ == null) {
if (messageWriteStatusCase_ == 2 &&
messageWriteStatus_ != tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Written.getDefaultInstance()) {
messageWriteStatus_ = tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Written.newBuilder((tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Written) messageWriteStatus_)
.mergeFrom(value).buildPartial();
} else {
messageWriteStatus_ = value;
}
onChanged();
} else {
if (messageWriteStatusCase_ == 2) {
writtenBuilder_.mergeFrom(value);
} else {
writtenBuilder_.setMessage(value);
}
}
messageWriteStatusCase_ = 2;
return this;
}
/**
* .Ydb.Topic.StreamWriteMessage.WriteResponse.WriteAck.Written written = 2;
*/
public Builder clearWritten() {
if (writtenBuilder_ == null) {
if (messageWriteStatusCase_ == 2) {
messageWriteStatusCase_ = 0;
messageWriteStatus_ = null;
onChanged();
}
} else {
if (messageWriteStatusCase_ == 2) {
messageWriteStatusCase_ = 0;
messageWriteStatus_ = null;
}
writtenBuilder_.clear();
}
return this;
}
/**
* .Ydb.Topic.StreamWriteMessage.WriteResponse.WriteAck.Written written = 2;
*/
public tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Written.Builder getWrittenBuilder() {
return getWrittenFieldBuilder().getBuilder();
}
/**
* .Ydb.Topic.StreamWriteMessage.WriteResponse.WriteAck.Written written = 2;
*/
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.WrittenOrBuilder getWrittenOrBuilder() {
if ((messageWriteStatusCase_ == 2) && (writtenBuilder_ != null)) {
return writtenBuilder_.getMessageOrBuilder();
} else {
if (messageWriteStatusCase_ == 2) {
return (tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Written) messageWriteStatus_;
}
return tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Written.getDefaultInstance();
}
}
/**
* .Ydb.Topic.StreamWriteMessage.WriteResponse.WriteAck.Written written = 2;
*/
private com.google.protobuf.SingleFieldBuilderV3<
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Written, tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Written.Builder, tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.WrittenOrBuilder>
getWrittenFieldBuilder() {
if (writtenBuilder_ == null) {
if (!(messageWriteStatusCase_ == 2)) {
messageWriteStatus_ = tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Written.getDefaultInstance();
}
writtenBuilder_ = new com.google.protobuf.SingleFieldBuilderV3<
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Written, tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Written.Builder, tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.WrittenOrBuilder>(
(tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Written) messageWriteStatus_,
getParentForChildren(),
isClean());
messageWriteStatus_ = null;
}
messageWriteStatusCase_ = 2;
onChanged();
return writtenBuilder_;
}
private com.google.protobuf.SingleFieldBuilderV3<
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Skipped, tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Skipped.Builder, tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.SkippedOrBuilder> skippedBuilder_;
/**
* .Ydb.Topic.StreamWriteMessage.WriteResponse.WriteAck.Skipped skipped = 3;
* @return Whether the skipped field is set.
*/
@java.lang.Override
public boolean hasSkipped() {
return messageWriteStatusCase_ == 3;
}
/**
* .Ydb.Topic.StreamWriteMessage.WriteResponse.WriteAck.Skipped skipped = 3;
* @return The skipped.
*/
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Skipped getSkipped() {
if (skippedBuilder_ == null) {
if (messageWriteStatusCase_ == 3) {
return (tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Skipped) messageWriteStatus_;
}
return tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Skipped.getDefaultInstance();
} else {
if (messageWriteStatusCase_ == 3) {
return skippedBuilder_.getMessage();
}
return tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Skipped.getDefaultInstance();
}
}
/**
* .Ydb.Topic.StreamWriteMessage.WriteResponse.WriteAck.Skipped skipped = 3;
*/
public Builder setSkipped(tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Skipped value) {
if (skippedBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
messageWriteStatus_ = value;
onChanged();
} else {
skippedBuilder_.setMessage(value);
}
messageWriteStatusCase_ = 3;
return this;
}
/**
* .Ydb.Topic.StreamWriteMessage.WriteResponse.WriteAck.Skipped skipped = 3;
*/
public Builder setSkipped(
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Skipped.Builder builderForValue) {
if (skippedBuilder_ == null) {
messageWriteStatus_ = builderForValue.build();
onChanged();
} else {
skippedBuilder_.setMessage(builderForValue.build());
}
messageWriteStatusCase_ = 3;
return this;
}
/**
* .Ydb.Topic.StreamWriteMessage.WriteResponse.WriteAck.Skipped skipped = 3;
*/
public Builder mergeSkipped(tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Skipped value) {
if (skippedBuilder_ == null) {
if (messageWriteStatusCase_ == 3 &&
messageWriteStatus_ != tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Skipped.getDefaultInstance()) {
messageWriteStatus_ = tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Skipped.newBuilder((tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Skipped) messageWriteStatus_)
.mergeFrom(value).buildPartial();
} else {
messageWriteStatus_ = value;
}
onChanged();
} else {
if (messageWriteStatusCase_ == 3) {
skippedBuilder_.mergeFrom(value);
} else {
skippedBuilder_.setMessage(value);
}
}
messageWriteStatusCase_ = 3;
return this;
}
/**
* .Ydb.Topic.StreamWriteMessage.WriteResponse.WriteAck.Skipped skipped = 3;
*/
public Builder clearSkipped() {
if (skippedBuilder_ == null) {
if (messageWriteStatusCase_ == 3) {
messageWriteStatusCase_ = 0;
messageWriteStatus_ = null;
onChanged();
}
} else {
if (messageWriteStatusCase_ == 3) {
messageWriteStatusCase_ = 0;
messageWriteStatus_ = null;
}
skippedBuilder_.clear();
}
return this;
}
/**
* .Ydb.Topic.StreamWriteMessage.WriteResponse.WriteAck.Skipped skipped = 3;
*/
public tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Skipped.Builder getSkippedBuilder() {
return getSkippedFieldBuilder().getBuilder();
}
/**
* .Ydb.Topic.StreamWriteMessage.WriteResponse.WriteAck.Skipped skipped = 3;
*/
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.SkippedOrBuilder getSkippedOrBuilder() {
if ((messageWriteStatusCase_ == 3) && (skippedBuilder_ != null)) {
return skippedBuilder_.getMessageOrBuilder();
} else {
if (messageWriteStatusCase_ == 3) {
return (tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Skipped) messageWriteStatus_;
}
return tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Skipped.getDefaultInstance();
}
}
/**
* .Ydb.Topic.StreamWriteMessage.WriteResponse.WriteAck.Skipped skipped = 3;
*/
private com.google.protobuf.SingleFieldBuilderV3<
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Skipped, tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Skipped.Builder, tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.SkippedOrBuilder>
getSkippedFieldBuilder() {
if (skippedBuilder_ == null) {
if (!(messageWriteStatusCase_ == 3)) {
messageWriteStatus_ = tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Skipped.getDefaultInstance();
}
skippedBuilder_ = new com.google.protobuf.SingleFieldBuilderV3<
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Skipped, tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Skipped.Builder, tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.SkippedOrBuilder>(
(tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Skipped) messageWriteStatus_,
getParentForChildren(),
isClean());
messageWriteStatus_ = null;
}
messageWriteStatusCase_ = 3;
onChanged();
return skippedBuilder_;
}
@java.lang.Override
public final Builder setUnknownFields(
final com.google.protobuf.UnknownFieldSet unknownFields) {
return super.setUnknownFields(unknownFields);
}
@java.lang.Override
public final Builder mergeUnknownFields(
final com.google.protobuf.UnknownFieldSet unknownFields) {
return super.mergeUnknownFields(unknownFields);
}
// @@protoc_insertion_point(builder_scope:Ydb.Topic.StreamWriteMessage.WriteResponse.WriteAck)
}
// @@protoc_insertion_point(class_scope:Ydb.Topic.StreamWriteMessage.WriteResponse.WriteAck)
private static final tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck DEFAULT_INSTANCE;
static {
DEFAULT_INSTANCE = new tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck();
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck getDefaultInstance() {
return DEFAULT_INSTANCE;
}
private static final com.google.protobuf.Parser
PARSER = new com.google.protobuf.AbstractParser() {
@java.lang.Override
public WriteAck parsePartialFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
Builder builder = newBuilder();
try {
builder.mergeFrom(input, extensionRegistry);
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.setUnfinishedMessage(builder.buildPartial());
} catch (com.google.protobuf.UninitializedMessageException e) {
throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial());
} catch (java.io.IOException e) {
throw new com.google.protobuf.InvalidProtocolBufferException(e)
.setUnfinishedMessage(builder.buildPartial());
}
return builder.buildPartial();
}
};
public static com.google.protobuf.Parser parser() {
return PARSER;
}
@java.lang.Override
public com.google.protobuf.Parser getParserForType() {
return PARSER;
}
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck getDefaultInstanceForType() {
return DEFAULT_INSTANCE;
}
}
public interface WriteStatisticsOrBuilder extends
// @@protoc_insertion_point(interface_extends:Ydb.Topic.StreamWriteMessage.WriteResponse.WriteStatistics)
com.google.protobuf.MessageOrBuilder {
/**
*
* Time spent in persisting of data. Same for each message in response.
*
*
* .google.protobuf.Duration persisting_time = 1;
* @return Whether the persistingTime field is set.
*/
boolean hasPersistingTime();
/**
*
* Time spent in persisting of data. Same for each message in response.
*
*
* .google.protobuf.Duration persisting_time = 1;
* @return The persistingTime.
*/
com.google.protobuf.Duration getPersistingTime();
/**
*
* Time spent in persisting of data. Same for each message in response.
*
*
* .google.protobuf.Duration persisting_time = 1;
*/
com.google.protobuf.DurationOrBuilder getPersistingTimeOrBuilder();
/**
*
* Time spent in queue before persisting, minimal of all messages in response.
*
*
* .google.protobuf.Duration min_queue_wait_time = 2;
* @return Whether the minQueueWaitTime field is set.
*/
boolean hasMinQueueWaitTime();
/**
*
* Time spent in queue before persisting, minimal of all messages in response.
*
*
* .google.protobuf.Duration min_queue_wait_time = 2;
* @return The minQueueWaitTime.
*/
com.google.protobuf.Duration getMinQueueWaitTime();
/**
*
* Time spent in queue before persisting, minimal of all messages in response.
*
*
* .google.protobuf.Duration min_queue_wait_time = 2;
*/
com.google.protobuf.DurationOrBuilder getMinQueueWaitTimeOrBuilder();
/**
*
* Time spent in queue before persisting, maximal of all messages in response.
*
*
* .google.protobuf.Duration max_queue_wait_time = 3;
* @return Whether the maxQueueWaitTime field is set.
*/
boolean hasMaxQueueWaitTime();
/**
*
* Time spent in queue before persisting, maximal of all messages in response.
*
*
* .google.protobuf.Duration max_queue_wait_time = 3;
* @return The maxQueueWaitTime.
*/
com.google.protobuf.Duration getMaxQueueWaitTime();
/**
*
* Time spent in queue before persisting, maximal of all messages in response.
*
*
* .google.protobuf.Duration max_queue_wait_time = 3;
*/
com.google.protobuf.DurationOrBuilder getMaxQueueWaitTimeOrBuilder();
/**
*
* Time spent awaiting for partition write quota. Same for each message in response.
*
*
* .google.protobuf.Duration partition_quota_wait_time = 4;
* @return Whether the partitionQuotaWaitTime field is set.
*/
boolean hasPartitionQuotaWaitTime();
/**
*
* Time spent awaiting for partition write quota. Same for each message in response.
*
*
* .google.protobuf.Duration partition_quota_wait_time = 4;
* @return The partitionQuotaWaitTime.
*/
com.google.protobuf.Duration getPartitionQuotaWaitTime();
/**
*
* Time spent awaiting for partition write quota. Same for each message in response.
*
*
* .google.protobuf.Duration partition_quota_wait_time = 4;
*/
com.google.protobuf.DurationOrBuilder getPartitionQuotaWaitTimeOrBuilder();
/**
*
* Time spent awaiting for topic write quota. Same for each message in response.
*
*
* .google.protobuf.Duration topic_quota_wait_time = 5;
* @return Whether the topicQuotaWaitTime field is set.
*/
boolean hasTopicQuotaWaitTime();
/**
*
* Time spent awaiting for topic write quota. Same for each message in response.
*
*
* .google.protobuf.Duration topic_quota_wait_time = 5;
* @return The topicQuotaWaitTime.
*/
com.google.protobuf.Duration getTopicQuotaWaitTime();
/**
*
* Time spent awaiting for topic write quota. Same for each message in response.
*
*
* .google.protobuf.Duration topic_quota_wait_time = 5;
*/
com.google.protobuf.DurationOrBuilder getTopicQuotaWaitTimeOrBuilder();
}
/**
*
* Message with write statistics.
*
*
* Protobuf type {@code Ydb.Topic.StreamWriteMessage.WriteResponse.WriteStatistics}
*/
public static final class WriteStatistics extends
com.google.protobuf.GeneratedMessageV3 implements
// @@protoc_insertion_point(message_implements:Ydb.Topic.StreamWriteMessage.WriteResponse.WriteStatistics)
WriteStatisticsOrBuilder {
private static final long serialVersionUID = 0L;
// Use WriteStatistics.newBuilder() to construct.
private WriteStatistics(com.google.protobuf.GeneratedMessageV3.Builder> builder) {
super(builder);
}
private WriteStatistics() {
}
@java.lang.Override
@SuppressWarnings({"unused"})
protected java.lang.Object newInstance(
UnusedPrivateParameter unused) {
return new WriteStatistics();
}
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_StreamWriteMessage_WriteResponse_WriteStatistics_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_StreamWriteMessage_WriteResponse_WriteStatistics_fieldAccessorTable
.ensureFieldAccessorsInitialized(
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteStatistics.class, tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteStatistics.Builder.class);
}
private int bitField0_;
public static final int PERSISTING_TIME_FIELD_NUMBER = 1;
private com.google.protobuf.Duration persistingTime_;
/**
*
* Time spent in persisting of data. Same for each message in response.
*
*
* .google.protobuf.Duration persisting_time = 1;
* @return Whether the persistingTime field is set.
*/
@java.lang.Override
public boolean hasPersistingTime() {
return ((bitField0_ & 0x00000001) != 0);
}
/**
*
* Time spent in persisting of data. Same for each message in response.
*
*
* .google.protobuf.Duration persisting_time = 1;
* @return The persistingTime.
*/
@java.lang.Override
public com.google.protobuf.Duration getPersistingTime() {
return persistingTime_ == null ? com.google.protobuf.Duration.getDefaultInstance() : persistingTime_;
}
/**
*
* Time spent in persisting of data. Same for each message in response.
*
*
* .google.protobuf.Duration persisting_time = 1;
*/
@java.lang.Override
public com.google.protobuf.DurationOrBuilder getPersistingTimeOrBuilder() {
return persistingTime_ == null ? com.google.protobuf.Duration.getDefaultInstance() : persistingTime_;
}
public static final int MIN_QUEUE_WAIT_TIME_FIELD_NUMBER = 2;
private com.google.protobuf.Duration minQueueWaitTime_;
/**
*
* Time spent in queue before persisting, minimal of all messages in response.
*
*
* .google.protobuf.Duration min_queue_wait_time = 2;
* @return Whether the minQueueWaitTime field is set.
*/
@java.lang.Override
public boolean hasMinQueueWaitTime() {
return ((bitField0_ & 0x00000002) != 0);
}
/**
*
* Time spent in queue before persisting, minimal of all messages in response.
*
*
* .google.protobuf.Duration min_queue_wait_time = 2;
* @return The minQueueWaitTime.
*/
@java.lang.Override
public com.google.protobuf.Duration getMinQueueWaitTime() {
return minQueueWaitTime_ == null ? com.google.protobuf.Duration.getDefaultInstance() : minQueueWaitTime_;
}
/**
*
* Time spent in queue before persisting, minimal of all messages in response.
*
*
* .google.protobuf.Duration min_queue_wait_time = 2;
*/
@java.lang.Override
public com.google.protobuf.DurationOrBuilder getMinQueueWaitTimeOrBuilder() {
return minQueueWaitTime_ == null ? com.google.protobuf.Duration.getDefaultInstance() : minQueueWaitTime_;
}
public static final int MAX_QUEUE_WAIT_TIME_FIELD_NUMBER = 3;
private com.google.protobuf.Duration maxQueueWaitTime_;
/**
*
* Time spent in queue before persisting, maximal of all messages in response.
*
*
* .google.protobuf.Duration max_queue_wait_time = 3;
* @return Whether the maxQueueWaitTime field is set.
*/
@java.lang.Override
public boolean hasMaxQueueWaitTime() {
return ((bitField0_ & 0x00000004) != 0);
}
/**
*
* Time spent in queue before persisting, maximal of all messages in response.
*
*
* .google.protobuf.Duration max_queue_wait_time = 3;
* @return The maxQueueWaitTime.
*/
@java.lang.Override
public com.google.protobuf.Duration getMaxQueueWaitTime() {
return maxQueueWaitTime_ == null ? com.google.protobuf.Duration.getDefaultInstance() : maxQueueWaitTime_;
}
/**
*
* Time spent in queue before persisting, maximal of all messages in response.
*
*
* .google.protobuf.Duration max_queue_wait_time = 3;
*/
@java.lang.Override
public com.google.protobuf.DurationOrBuilder getMaxQueueWaitTimeOrBuilder() {
return maxQueueWaitTime_ == null ? com.google.protobuf.Duration.getDefaultInstance() : maxQueueWaitTime_;
}
public static final int PARTITION_QUOTA_WAIT_TIME_FIELD_NUMBER = 4;
private com.google.protobuf.Duration partitionQuotaWaitTime_;
/**
*
* Time spent awaiting for partition write quota. Same for each message in response.
*
*
* .google.protobuf.Duration partition_quota_wait_time = 4;
* @return Whether the partitionQuotaWaitTime field is set.
*/
@java.lang.Override
public boolean hasPartitionQuotaWaitTime() {
return ((bitField0_ & 0x00000008) != 0);
}
/**
*
* Time spent awaiting for partition write quota. Same for each message in response.
*
*
* .google.protobuf.Duration partition_quota_wait_time = 4;
* @return The partitionQuotaWaitTime.
*/
@java.lang.Override
public com.google.protobuf.Duration getPartitionQuotaWaitTime() {
return partitionQuotaWaitTime_ == null ? com.google.protobuf.Duration.getDefaultInstance() : partitionQuotaWaitTime_;
}
/**
*
* Time spent awaiting for partition write quota. Same for each message in response.
*
*
* .google.protobuf.Duration partition_quota_wait_time = 4;
*/
@java.lang.Override
public com.google.protobuf.DurationOrBuilder getPartitionQuotaWaitTimeOrBuilder() {
return partitionQuotaWaitTime_ == null ? com.google.protobuf.Duration.getDefaultInstance() : partitionQuotaWaitTime_;
}
public static final int TOPIC_QUOTA_WAIT_TIME_FIELD_NUMBER = 5;
private com.google.protobuf.Duration topicQuotaWaitTime_;
/**
*
* Time spent awaiting for topic write quota. Same for each message in response.
*
*
* .google.protobuf.Duration topic_quota_wait_time = 5;
* @return Whether the topicQuotaWaitTime field is set.
*/
@java.lang.Override
public boolean hasTopicQuotaWaitTime() {
return ((bitField0_ & 0x00000010) != 0);
}
/**
*
* Time spent awaiting for topic write quota. Same for each message in response.
*
*
* .google.protobuf.Duration topic_quota_wait_time = 5;
* @return The topicQuotaWaitTime.
*/
@java.lang.Override
public com.google.protobuf.Duration getTopicQuotaWaitTime() {
return topicQuotaWaitTime_ == null ? com.google.protobuf.Duration.getDefaultInstance() : topicQuotaWaitTime_;
}
/**
*
* Time spent awaiting for topic write quota. Same for each message in response.
*
*
* .google.protobuf.Duration topic_quota_wait_time = 5;
*/
@java.lang.Override
public com.google.protobuf.DurationOrBuilder getTopicQuotaWaitTimeOrBuilder() {
return topicQuotaWaitTime_ == null ? com.google.protobuf.Duration.getDefaultInstance() : topicQuotaWaitTime_;
}
private byte memoizedIsInitialized = -1;
@java.lang.Override
public final boolean isInitialized() {
byte isInitialized = memoizedIsInitialized;
if (isInitialized == 1) return true;
if (isInitialized == 0) return false;
memoizedIsInitialized = 1;
return true;
}
@java.lang.Override
public void writeTo(com.google.protobuf.CodedOutputStream output)
throws java.io.IOException {
if (((bitField0_ & 0x00000001) != 0)) {
output.writeMessage(1, getPersistingTime());
}
if (((bitField0_ & 0x00000002) != 0)) {
output.writeMessage(2, getMinQueueWaitTime());
}
if (((bitField0_ & 0x00000004) != 0)) {
output.writeMessage(3, getMaxQueueWaitTime());
}
if (((bitField0_ & 0x00000008) != 0)) {
output.writeMessage(4, getPartitionQuotaWaitTime());
}
if (((bitField0_ & 0x00000010) != 0)) {
output.writeMessage(5, getTopicQuotaWaitTime());
}
getUnknownFields().writeTo(output);
}
@java.lang.Override
public int getSerializedSize() {
int size = memoizedSize;
if (size != -1) return size;
size = 0;
if (((bitField0_ & 0x00000001) != 0)) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(1, getPersistingTime());
}
if (((bitField0_ & 0x00000002) != 0)) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(2, getMinQueueWaitTime());
}
if (((bitField0_ & 0x00000004) != 0)) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(3, getMaxQueueWaitTime());
}
if (((bitField0_ & 0x00000008) != 0)) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(4, getPartitionQuotaWaitTime());
}
if (((bitField0_ & 0x00000010) != 0)) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(5, getTopicQuotaWaitTime());
}
size += getUnknownFields().getSerializedSize();
memoizedSize = size;
return size;
}
@java.lang.Override
public boolean equals(final java.lang.Object obj) {
if (obj == this) {
return true;
}
if (!(obj instanceof tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteStatistics)) {
return super.equals(obj);
}
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteStatistics other = (tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteStatistics) obj;
if (hasPersistingTime() != other.hasPersistingTime()) return false;
if (hasPersistingTime()) {
if (!getPersistingTime()
.equals(other.getPersistingTime())) return false;
}
if (hasMinQueueWaitTime() != other.hasMinQueueWaitTime()) return false;
if (hasMinQueueWaitTime()) {
if (!getMinQueueWaitTime()
.equals(other.getMinQueueWaitTime())) return false;
}
if (hasMaxQueueWaitTime() != other.hasMaxQueueWaitTime()) return false;
if (hasMaxQueueWaitTime()) {
if (!getMaxQueueWaitTime()
.equals(other.getMaxQueueWaitTime())) return false;
}
if (hasPartitionQuotaWaitTime() != other.hasPartitionQuotaWaitTime()) return false;
if (hasPartitionQuotaWaitTime()) {
if (!getPartitionQuotaWaitTime()
.equals(other.getPartitionQuotaWaitTime())) return false;
}
if (hasTopicQuotaWaitTime() != other.hasTopicQuotaWaitTime()) return false;
if (hasTopicQuotaWaitTime()) {
if (!getTopicQuotaWaitTime()
.equals(other.getTopicQuotaWaitTime())) return false;
}
if (!getUnknownFields().equals(other.getUnknownFields())) return false;
return true;
}
@java.lang.Override
public int hashCode() {
if (memoizedHashCode != 0) {
return memoizedHashCode;
}
int hash = 41;
hash = (19 * hash) + getDescriptor().hashCode();
if (hasPersistingTime()) {
hash = (37 * hash) + PERSISTING_TIME_FIELD_NUMBER;
hash = (53 * hash) + getPersistingTime().hashCode();
}
if (hasMinQueueWaitTime()) {
hash = (37 * hash) + MIN_QUEUE_WAIT_TIME_FIELD_NUMBER;
hash = (53 * hash) + getMinQueueWaitTime().hashCode();
}
if (hasMaxQueueWaitTime()) {
hash = (37 * hash) + MAX_QUEUE_WAIT_TIME_FIELD_NUMBER;
hash = (53 * hash) + getMaxQueueWaitTime().hashCode();
}
if (hasPartitionQuotaWaitTime()) {
hash = (37 * hash) + PARTITION_QUOTA_WAIT_TIME_FIELD_NUMBER;
hash = (53 * hash) + getPartitionQuotaWaitTime().hashCode();
}
if (hasTopicQuotaWaitTime()) {
hash = (37 * hash) + TOPIC_QUOTA_WAIT_TIME_FIELD_NUMBER;
hash = (53 * hash) + getTopicQuotaWaitTime().hashCode();
}
hash = (29 * hash) + getUnknownFields().hashCode();
memoizedHashCode = hash;
return hash;
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteStatistics parseFrom(
java.nio.ByteBuffer data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteStatistics parseFrom(
java.nio.ByteBuffer data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteStatistics parseFrom(
com.google.protobuf.ByteString data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteStatistics parseFrom(
com.google.protobuf.ByteString data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteStatistics parseFrom(byte[] data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteStatistics parseFrom(
byte[] data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteStatistics parseFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteStatistics parseFrom(
java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteStatistics parseDelimitedFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input);
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteStatistics parseDelimitedFrom(
java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteStatistics parseFrom(
com.google.protobuf.CodedInputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteStatistics parseFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry);
}
@java.lang.Override
public Builder newBuilderForType() { return newBuilder(); }
public static Builder newBuilder() {
return DEFAULT_INSTANCE.toBuilder();
}
public static Builder newBuilder(tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteStatistics prototype) {
return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
}
@java.lang.Override
public Builder toBuilder() {
return this == DEFAULT_INSTANCE
? new Builder() : new Builder().mergeFrom(this);
}
@java.lang.Override
protected Builder newBuilderForType(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
Builder builder = new Builder(parent);
return builder;
}
/**
*
* Message with write statistics.
*
*
* Protobuf type {@code Ydb.Topic.StreamWriteMessage.WriteResponse.WriteStatistics}
*/
public static final class Builder extends
com.google.protobuf.GeneratedMessageV3.Builder implements
// @@protoc_insertion_point(builder_implements:Ydb.Topic.StreamWriteMessage.WriteResponse.WriteStatistics)
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteStatisticsOrBuilder {
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_StreamWriteMessage_WriteResponse_WriteStatistics_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_StreamWriteMessage_WriteResponse_WriteStatistics_fieldAccessorTable
.ensureFieldAccessorsInitialized(
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteStatistics.class, tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteStatistics.Builder.class);
}
// Construct using tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteStatistics.newBuilder()
private Builder() {
maybeForceBuilderInitialization();
}
private Builder(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
super(parent);
maybeForceBuilderInitialization();
}
private void maybeForceBuilderInitialization() {
if (com.google.protobuf.GeneratedMessageV3
.alwaysUseFieldBuilders) {
getPersistingTimeFieldBuilder();
getMinQueueWaitTimeFieldBuilder();
getMaxQueueWaitTimeFieldBuilder();
getPartitionQuotaWaitTimeFieldBuilder();
getTopicQuotaWaitTimeFieldBuilder();
}
}
@java.lang.Override
public Builder clear() {
super.clear();
bitField0_ = 0;
persistingTime_ = null;
if (persistingTimeBuilder_ != null) {
persistingTimeBuilder_.dispose();
persistingTimeBuilder_ = null;
}
minQueueWaitTime_ = null;
if (minQueueWaitTimeBuilder_ != null) {
minQueueWaitTimeBuilder_.dispose();
minQueueWaitTimeBuilder_ = null;
}
maxQueueWaitTime_ = null;
if (maxQueueWaitTimeBuilder_ != null) {
maxQueueWaitTimeBuilder_.dispose();
maxQueueWaitTimeBuilder_ = null;
}
partitionQuotaWaitTime_ = null;
if (partitionQuotaWaitTimeBuilder_ != null) {
partitionQuotaWaitTimeBuilder_.dispose();
partitionQuotaWaitTimeBuilder_ = null;
}
topicQuotaWaitTime_ = null;
if (topicQuotaWaitTimeBuilder_ != null) {
topicQuotaWaitTimeBuilder_.dispose();
topicQuotaWaitTimeBuilder_ = null;
}
return this;
}
@java.lang.Override
public com.google.protobuf.Descriptors.Descriptor
getDescriptorForType() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_StreamWriteMessage_WriteResponse_WriteStatistics_descriptor;
}
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteStatistics getDefaultInstanceForType() {
return tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteStatistics.getDefaultInstance();
}
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteStatistics build() {
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteStatistics result = buildPartial();
if (!result.isInitialized()) {
throw newUninitializedMessageException(result);
}
return result;
}
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteStatistics buildPartial() {
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteStatistics result = new tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteStatistics(this);
if (bitField0_ != 0) { buildPartial0(result); }
onBuilt();
return result;
}
private void buildPartial0(tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteStatistics result) {
int from_bitField0_ = bitField0_;
int to_bitField0_ = 0;
if (((from_bitField0_ & 0x00000001) != 0)) {
result.persistingTime_ = persistingTimeBuilder_ == null
? persistingTime_
: persistingTimeBuilder_.build();
to_bitField0_ |= 0x00000001;
}
if (((from_bitField0_ & 0x00000002) != 0)) {
result.minQueueWaitTime_ = minQueueWaitTimeBuilder_ == null
? minQueueWaitTime_
: minQueueWaitTimeBuilder_.build();
to_bitField0_ |= 0x00000002;
}
if (((from_bitField0_ & 0x00000004) != 0)) {
result.maxQueueWaitTime_ = maxQueueWaitTimeBuilder_ == null
? maxQueueWaitTime_
: maxQueueWaitTimeBuilder_.build();
to_bitField0_ |= 0x00000004;
}
if (((from_bitField0_ & 0x00000008) != 0)) {
result.partitionQuotaWaitTime_ = partitionQuotaWaitTimeBuilder_ == null
? partitionQuotaWaitTime_
: partitionQuotaWaitTimeBuilder_.build();
to_bitField0_ |= 0x00000008;
}
if (((from_bitField0_ & 0x00000010) != 0)) {
result.topicQuotaWaitTime_ = topicQuotaWaitTimeBuilder_ == null
? topicQuotaWaitTime_
: topicQuotaWaitTimeBuilder_.build();
to_bitField0_ |= 0x00000010;
}
result.bitField0_ |= to_bitField0_;
}
@java.lang.Override
public Builder clone() {
return super.clone();
}
@java.lang.Override
public Builder setField(
com.google.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) {
return super.setField(field, value);
}
@java.lang.Override
public Builder clearField(
com.google.protobuf.Descriptors.FieldDescriptor field) {
return super.clearField(field);
}
@java.lang.Override
public Builder clearOneof(
com.google.protobuf.Descriptors.OneofDescriptor oneof) {
return super.clearOneof(oneof);
}
@java.lang.Override
public Builder setRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
int index, java.lang.Object value) {
return super.setRepeatedField(field, index, value);
}
@java.lang.Override
public Builder addRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) {
return super.addRepeatedField(field, value);
}
@java.lang.Override
public Builder mergeFrom(com.google.protobuf.Message other) {
if (other instanceof tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteStatistics) {
return mergeFrom((tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteStatistics)other);
} else {
super.mergeFrom(other);
return this;
}
}
public Builder mergeFrom(tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteStatistics other) {
if (other == tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteStatistics.getDefaultInstance()) return this;
if (other.hasPersistingTime()) {
mergePersistingTime(other.getPersistingTime());
}
if (other.hasMinQueueWaitTime()) {
mergeMinQueueWaitTime(other.getMinQueueWaitTime());
}
if (other.hasMaxQueueWaitTime()) {
mergeMaxQueueWaitTime(other.getMaxQueueWaitTime());
}
if (other.hasPartitionQuotaWaitTime()) {
mergePartitionQuotaWaitTime(other.getPartitionQuotaWaitTime());
}
if (other.hasTopicQuotaWaitTime()) {
mergeTopicQuotaWaitTime(other.getTopicQuotaWaitTime());
}
this.mergeUnknownFields(other.getUnknownFields());
onChanged();
return this;
}
@java.lang.Override
public final boolean isInitialized() {
return true;
}
@java.lang.Override
public Builder mergeFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
if (extensionRegistry == null) {
throw new java.lang.NullPointerException();
}
try {
boolean done = false;
while (!done) {
int tag = input.readTag();
switch (tag) {
case 0:
done = true;
break;
case 10: {
input.readMessage(
getPersistingTimeFieldBuilder().getBuilder(),
extensionRegistry);
bitField0_ |= 0x00000001;
break;
} // case 10
case 18: {
input.readMessage(
getMinQueueWaitTimeFieldBuilder().getBuilder(),
extensionRegistry);
bitField0_ |= 0x00000002;
break;
} // case 18
case 26: {
input.readMessage(
getMaxQueueWaitTimeFieldBuilder().getBuilder(),
extensionRegistry);
bitField0_ |= 0x00000004;
break;
} // case 26
case 34: {
input.readMessage(
getPartitionQuotaWaitTimeFieldBuilder().getBuilder(),
extensionRegistry);
bitField0_ |= 0x00000008;
break;
} // case 34
case 42: {
input.readMessage(
getTopicQuotaWaitTimeFieldBuilder().getBuilder(),
extensionRegistry);
bitField0_ |= 0x00000010;
break;
} // case 42
default: {
if (!super.parseUnknownField(input, extensionRegistry, tag)) {
done = true; // was an endgroup tag
}
break;
} // default:
} // switch (tag)
} // while (!done)
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.unwrapIOException();
} finally {
onChanged();
} // finally
return this;
}
private int bitField0_;
private com.google.protobuf.Duration persistingTime_;
private com.google.protobuf.SingleFieldBuilderV3<
com.google.protobuf.Duration, com.google.protobuf.Duration.Builder, com.google.protobuf.DurationOrBuilder> persistingTimeBuilder_;
/**
*
* Time spent in persisting of data. Same for each message in response.
*
*
* .google.protobuf.Duration persisting_time = 1;
* @return Whether the persistingTime field is set.
*/
public boolean hasPersistingTime() {
return ((bitField0_ & 0x00000001) != 0);
}
/**
*
* Time spent in persisting of data. Same for each message in response.
*
*
* .google.protobuf.Duration persisting_time = 1;
* @return The persistingTime.
*/
public com.google.protobuf.Duration getPersistingTime() {
if (persistingTimeBuilder_ == null) {
return persistingTime_ == null ? com.google.protobuf.Duration.getDefaultInstance() : persistingTime_;
} else {
return persistingTimeBuilder_.getMessage();
}
}
/**
*
* Time spent in persisting of data. Same for each message in response.
*
*
* .google.protobuf.Duration persisting_time = 1;
*/
public Builder setPersistingTime(com.google.protobuf.Duration value) {
if (persistingTimeBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
persistingTime_ = value;
} else {
persistingTimeBuilder_.setMessage(value);
}
bitField0_ |= 0x00000001;
onChanged();
return this;
}
/**
*
* Time spent in persisting of data. Same for each message in response.
*
*
* .google.protobuf.Duration persisting_time = 1;
*/
public Builder setPersistingTime(
com.google.protobuf.Duration.Builder builderForValue) {
if (persistingTimeBuilder_ == null) {
persistingTime_ = builderForValue.build();
} else {
persistingTimeBuilder_.setMessage(builderForValue.build());
}
bitField0_ |= 0x00000001;
onChanged();
return this;
}
/**
*
* Time spent in persisting of data. Same for each message in response.
*
*
* .google.protobuf.Duration persisting_time = 1;
*/
public Builder mergePersistingTime(com.google.protobuf.Duration value) {
if (persistingTimeBuilder_ == null) {
if (((bitField0_ & 0x00000001) != 0) &&
persistingTime_ != null &&
persistingTime_ != com.google.protobuf.Duration.getDefaultInstance()) {
getPersistingTimeBuilder().mergeFrom(value);
} else {
persistingTime_ = value;
}
} else {
persistingTimeBuilder_.mergeFrom(value);
}
if (persistingTime_ != null) {
bitField0_ |= 0x00000001;
onChanged();
}
return this;
}
/**
*
* Time spent in persisting of data. Same for each message in response.
*
*
* .google.protobuf.Duration persisting_time = 1;
*/
public Builder clearPersistingTime() {
bitField0_ = (bitField0_ & ~0x00000001);
persistingTime_ = null;
if (persistingTimeBuilder_ != null) {
persistingTimeBuilder_.dispose();
persistingTimeBuilder_ = null;
}
onChanged();
return this;
}
/**
*
* Time spent in persisting of data. Same for each message in response.
*
*
* .google.protobuf.Duration persisting_time = 1;
*/
public com.google.protobuf.Duration.Builder getPersistingTimeBuilder() {
bitField0_ |= 0x00000001;
onChanged();
return getPersistingTimeFieldBuilder().getBuilder();
}
/**
*
* Time spent in persisting of data. Same for each message in response.
*
*
* .google.protobuf.Duration persisting_time = 1;
*/
public com.google.protobuf.DurationOrBuilder getPersistingTimeOrBuilder() {
if (persistingTimeBuilder_ != null) {
return persistingTimeBuilder_.getMessageOrBuilder();
} else {
return persistingTime_ == null ?
com.google.protobuf.Duration.getDefaultInstance() : persistingTime_;
}
}
/**
*
* Time spent in persisting of data. Same for each message in response.
*
*
* .google.protobuf.Duration persisting_time = 1;
*/
private com.google.protobuf.SingleFieldBuilderV3<
com.google.protobuf.Duration, com.google.protobuf.Duration.Builder, com.google.protobuf.DurationOrBuilder>
getPersistingTimeFieldBuilder() {
if (persistingTimeBuilder_ == null) {
persistingTimeBuilder_ = new com.google.protobuf.SingleFieldBuilderV3<
com.google.protobuf.Duration, com.google.protobuf.Duration.Builder, com.google.protobuf.DurationOrBuilder>(
getPersistingTime(),
getParentForChildren(),
isClean());
persistingTime_ = null;
}
return persistingTimeBuilder_;
}
private com.google.protobuf.Duration minQueueWaitTime_;
private com.google.protobuf.SingleFieldBuilderV3<
com.google.protobuf.Duration, com.google.protobuf.Duration.Builder, com.google.protobuf.DurationOrBuilder> minQueueWaitTimeBuilder_;
/**
*
* Time spent in queue before persisting, minimal of all messages in response.
*
*
* .google.protobuf.Duration min_queue_wait_time = 2;
* @return Whether the minQueueWaitTime field is set.
*/
public boolean hasMinQueueWaitTime() {
return ((bitField0_ & 0x00000002) != 0);
}
/**
*
* Time spent in queue before persisting, minimal of all messages in response.
*
*
* .google.protobuf.Duration min_queue_wait_time = 2;
* @return The minQueueWaitTime.
*/
public com.google.protobuf.Duration getMinQueueWaitTime() {
if (minQueueWaitTimeBuilder_ == null) {
return minQueueWaitTime_ == null ? com.google.protobuf.Duration.getDefaultInstance() : minQueueWaitTime_;
} else {
return minQueueWaitTimeBuilder_.getMessage();
}
}
/**
*
* Time spent in queue before persisting, minimal of all messages in response.
*
*
* .google.protobuf.Duration min_queue_wait_time = 2;
*/
public Builder setMinQueueWaitTime(com.google.protobuf.Duration value) {
if (minQueueWaitTimeBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
minQueueWaitTime_ = value;
} else {
minQueueWaitTimeBuilder_.setMessage(value);
}
bitField0_ |= 0x00000002;
onChanged();
return this;
}
/**
*
* Time spent in queue before persisting, minimal of all messages in response.
*
*
* .google.protobuf.Duration min_queue_wait_time = 2;
*/
public Builder setMinQueueWaitTime(
com.google.protobuf.Duration.Builder builderForValue) {
if (minQueueWaitTimeBuilder_ == null) {
minQueueWaitTime_ = builderForValue.build();
} else {
minQueueWaitTimeBuilder_.setMessage(builderForValue.build());
}
bitField0_ |= 0x00000002;
onChanged();
return this;
}
/**
*
* Time spent in queue before persisting, minimal of all messages in response.
*
*
* .google.protobuf.Duration min_queue_wait_time = 2;
*/
public Builder mergeMinQueueWaitTime(com.google.protobuf.Duration value) {
if (minQueueWaitTimeBuilder_ == null) {
if (((bitField0_ & 0x00000002) != 0) &&
minQueueWaitTime_ != null &&
minQueueWaitTime_ != com.google.protobuf.Duration.getDefaultInstance()) {
getMinQueueWaitTimeBuilder().mergeFrom(value);
} else {
minQueueWaitTime_ = value;
}
} else {
minQueueWaitTimeBuilder_.mergeFrom(value);
}
if (minQueueWaitTime_ != null) {
bitField0_ |= 0x00000002;
onChanged();
}
return this;
}
/**
*
* Time spent in queue before persisting, minimal of all messages in response.
*
*
* .google.protobuf.Duration min_queue_wait_time = 2;
*/
public Builder clearMinQueueWaitTime() {
bitField0_ = (bitField0_ & ~0x00000002);
minQueueWaitTime_ = null;
if (minQueueWaitTimeBuilder_ != null) {
minQueueWaitTimeBuilder_.dispose();
minQueueWaitTimeBuilder_ = null;
}
onChanged();
return this;
}
/**
*
* Time spent in queue before persisting, minimal of all messages in response.
*
*
* .google.protobuf.Duration min_queue_wait_time = 2;
*/
public com.google.protobuf.Duration.Builder getMinQueueWaitTimeBuilder() {
bitField0_ |= 0x00000002;
onChanged();
return getMinQueueWaitTimeFieldBuilder().getBuilder();
}
/**
*
* Time spent in queue before persisting, minimal of all messages in response.
*
*
* .google.protobuf.Duration min_queue_wait_time = 2;
*/
public com.google.protobuf.DurationOrBuilder getMinQueueWaitTimeOrBuilder() {
if (minQueueWaitTimeBuilder_ != null) {
return minQueueWaitTimeBuilder_.getMessageOrBuilder();
} else {
return minQueueWaitTime_ == null ?
com.google.protobuf.Duration.getDefaultInstance() : minQueueWaitTime_;
}
}
/**
*
* Time spent in queue before persisting, minimal of all messages in response.
*
*
* .google.protobuf.Duration min_queue_wait_time = 2;
*/
private com.google.protobuf.SingleFieldBuilderV3<
com.google.protobuf.Duration, com.google.protobuf.Duration.Builder, com.google.protobuf.DurationOrBuilder>
getMinQueueWaitTimeFieldBuilder() {
if (minQueueWaitTimeBuilder_ == null) {
minQueueWaitTimeBuilder_ = new com.google.protobuf.SingleFieldBuilderV3<
com.google.protobuf.Duration, com.google.protobuf.Duration.Builder, com.google.protobuf.DurationOrBuilder>(
getMinQueueWaitTime(),
getParentForChildren(),
isClean());
minQueueWaitTime_ = null;
}
return minQueueWaitTimeBuilder_;
}
private com.google.protobuf.Duration maxQueueWaitTime_;
private com.google.protobuf.SingleFieldBuilderV3<
com.google.protobuf.Duration, com.google.protobuf.Duration.Builder, com.google.protobuf.DurationOrBuilder> maxQueueWaitTimeBuilder_;
/**
*
* Time spent in queue before persisting, maximal of all messages in response.
*
*
* .google.protobuf.Duration max_queue_wait_time = 3;
* @return Whether the maxQueueWaitTime field is set.
*/
public boolean hasMaxQueueWaitTime() {
return ((bitField0_ & 0x00000004) != 0);
}
/**
*
* Time spent in queue before persisting, maximal of all messages in response.
*
*
* .google.protobuf.Duration max_queue_wait_time = 3;
* @return The maxQueueWaitTime.
*/
public com.google.protobuf.Duration getMaxQueueWaitTime() {
if (maxQueueWaitTimeBuilder_ == null) {
return maxQueueWaitTime_ == null ? com.google.protobuf.Duration.getDefaultInstance() : maxQueueWaitTime_;
} else {
return maxQueueWaitTimeBuilder_.getMessage();
}
}
/**
*
* Time spent in queue before persisting, maximal of all messages in response.
*
*
* .google.protobuf.Duration max_queue_wait_time = 3;
*/
public Builder setMaxQueueWaitTime(com.google.protobuf.Duration value) {
if (maxQueueWaitTimeBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
maxQueueWaitTime_ = value;
} else {
maxQueueWaitTimeBuilder_.setMessage(value);
}
bitField0_ |= 0x00000004;
onChanged();
return this;
}
/**
*
* Time spent in queue before persisting, maximal of all messages in response.
*
*
* .google.protobuf.Duration max_queue_wait_time = 3;
*/
public Builder setMaxQueueWaitTime(
com.google.protobuf.Duration.Builder builderForValue) {
if (maxQueueWaitTimeBuilder_ == null) {
maxQueueWaitTime_ = builderForValue.build();
} else {
maxQueueWaitTimeBuilder_.setMessage(builderForValue.build());
}
bitField0_ |= 0x00000004;
onChanged();
return this;
}
/**
*
* Time spent in queue before persisting, maximal of all messages in response.
*
*
* .google.protobuf.Duration max_queue_wait_time = 3;
*/
public Builder mergeMaxQueueWaitTime(com.google.protobuf.Duration value) {
if (maxQueueWaitTimeBuilder_ == null) {
if (((bitField0_ & 0x00000004) != 0) &&
maxQueueWaitTime_ != null &&
maxQueueWaitTime_ != com.google.protobuf.Duration.getDefaultInstance()) {
getMaxQueueWaitTimeBuilder().mergeFrom(value);
} else {
maxQueueWaitTime_ = value;
}
} else {
maxQueueWaitTimeBuilder_.mergeFrom(value);
}
if (maxQueueWaitTime_ != null) {
bitField0_ |= 0x00000004;
onChanged();
}
return this;
}
/**
*
* Time spent in queue before persisting, maximal of all messages in response.
*
*
* .google.protobuf.Duration max_queue_wait_time = 3;
*/
public Builder clearMaxQueueWaitTime() {
bitField0_ = (bitField0_ & ~0x00000004);
maxQueueWaitTime_ = null;
if (maxQueueWaitTimeBuilder_ != null) {
maxQueueWaitTimeBuilder_.dispose();
maxQueueWaitTimeBuilder_ = null;
}
onChanged();
return this;
}
/**
*
* Time spent in queue before persisting, maximal of all messages in response.
*
*
* .google.protobuf.Duration max_queue_wait_time = 3;
*/
public com.google.protobuf.Duration.Builder getMaxQueueWaitTimeBuilder() {
bitField0_ |= 0x00000004;
onChanged();
return getMaxQueueWaitTimeFieldBuilder().getBuilder();
}
/**
*
* Time spent in queue before persisting, maximal of all messages in response.
*
*
* .google.protobuf.Duration max_queue_wait_time = 3;
*/
public com.google.protobuf.DurationOrBuilder getMaxQueueWaitTimeOrBuilder() {
if (maxQueueWaitTimeBuilder_ != null) {
return maxQueueWaitTimeBuilder_.getMessageOrBuilder();
} else {
return maxQueueWaitTime_ == null ?
com.google.protobuf.Duration.getDefaultInstance() : maxQueueWaitTime_;
}
}
/**
*
* Time spent in queue before persisting, maximal of all messages in response.
*
*
* .google.protobuf.Duration max_queue_wait_time = 3;
*/
private com.google.protobuf.SingleFieldBuilderV3<
com.google.protobuf.Duration, com.google.protobuf.Duration.Builder, com.google.protobuf.DurationOrBuilder>
getMaxQueueWaitTimeFieldBuilder() {
if (maxQueueWaitTimeBuilder_ == null) {
maxQueueWaitTimeBuilder_ = new com.google.protobuf.SingleFieldBuilderV3<
com.google.protobuf.Duration, com.google.protobuf.Duration.Builder, com.google.protobuf.DurationOrBuilder>(
getMaxQueueWaitTime(),
getParentForChildren(),
isClean());
maxQueueWaitTime_ = null;
}
return maxQueueWaitTimeBuilder_;
}
private com.google.protobuf.Duration partitionQuotaWaitTime_;
private com.google.protobuf.SingleFieldBuilderV3<
com.google.protobuf.Duration, com.google.protobuf.Duration.Builder, com.google.protobuf.DurationOrBuilder> partitionQuotaWaitTimeBuilder_;
/**
*
* Time spent awaiting for partition write quota. Same for each message in response.
*
*
* .google.protobuf.Duration partition_quota_wait_time = 4;
* @return Whether the partitionQuotaWaitTime field is set.
*/
public boolean hasPartitionQuotaWaitTime() {
return ((bitField0_ & 0x00000008) != 0);
}
/**
*
* Time spent awaiting for partition write quota. Same for each message in response.
*
*
* .google.protobuf.Duration partition_quota_wait_time = 4;
* @return The partitionQuotaWaitTime.
*/
public com.google.protobuf.Duration getPartitionQuotaWaitTime() {
if (partitionQuotaWaitTimeBuilder_ == null) {
return partitionQuotaWaitTime_ == null ? com.google.protobuf.Duration.getDefaultInstance() : partitionQuotaWaitTime_;
} else {
return partitionQuotaWaitTimeBuilder_.getMessage();
}
}
/**
*
* Time spent awaiting for partition write quota. Same for each message in response.
*
*
* .google.protobuf.Duration partition_quota_wait_time = 4;
*/
public Builder setPartitionQuotaWaitTime(com.google.protobuf.Duration value) {
if (partitionQuotaWaitTimeBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
partitionQuotaWaitTime_ = value;
} else {
partitionQuotaWaitTimeBuilder_.setMessage(value);
}
bitField0_ |= 0x00000008;
onChanged();
return this;
}
/**
*
* Time spent awaiting for partition write quota. Same for each message in response.
*
*
* .google.protobuf.Duration partition_quota_wait_time = 4;
*/
public Builder setPartitionQuotaWaitTime(
com.google.protobuf.Duration.Builder builderForValue) {
if (partitionQuotaWaitTimeBuilder_ == null) {
partitionQuotaWaitTime_ = builderForValue.build();
} else {
partitionQuotaWaitTimeBuilder_.setMessage(builderForValue.build());
}
bitField0_ |= 0x00000008;
onChanged();
return this;
}
/**
*
* Time spent awaiting for partition write quota. Same for each message in response.
*
*
* .google.protobuf.Duration partition_quota_wait_time = 4;
*/
public Builder mergePartitionQuotaWaitTime(com.google.protobuf.Duration value) {
if (partitionQuotaWaitTimeBuilder_ == null) {
if (((bitField0_ & 0x00000008) != 0) &&
partitionQuotaWaitTime_ != null &&
partitionQuotaWaitTime_ != com.google.protobuf.Duration.getDefaultInstance()) {
getPartitionQuotaWaitTimeBuilder().mergeFrom(value);
} else {
partitionQuotaWaitTime_ = value;
}
} else {
partitionQuotaWaitTimeBuilder_.mergeFrom(value);
}
if (partitionQuotaWaitTime_ != null) {
bitField0_ |= 0x00000008;
onChanged();
}
return this;
}
/**
*
* Time spent awaiting for partition write quota. Same for each message in response.
*
*
* .google.protobuf.Duration partition_quota_wait_time = 4;
*/
public Builder clearPartitionQuotaWaitTime() {
bitField0_ = (bitField0_ & ~0x00000008);
partitionQuotaWaitTime_ = null;
if (partitionQuotaWaitTimeBuilder_ != null) {
partitionQuotaWaitTimeBuilder_.dispose();
partitionQuotaWaitTimeBuilder_ = null;
}
onChanged();
return this;
}
/**
*
* Time spent awaiting for partition write quota. Same for each message in response.
*
*
* .google.protobuf.Duration partition_quota_wait_time = 4;
*/
public com.google.protobuf.Duration.Builder getPartitionQuotaWaitTimeBuilder() {
bitField0_ |= 0x00000008;
onChanged();
return getPartitionQuotaWaitTimeFieldBuilder().getBuilder();
}
/**
*
* Time spent awaiting for partition write quota. Same for each message in response.
*
*
* .google.protobuf.Duration partition_quota_wait_time = 4;
*/
public com.google.protobuf.DurationOrBuilder getPartitionQuotaWaitTimeOrBuilder() {
if (partitionQuotaWaitTimeBuilder_ != null) {
return partitionQuotaWaitTimeBuilder_.getMessageOrBuilder();
} else {
return partitionQuotaWaitTime_ == null ?
com.google.protobuf.Duration.getDefaultInstance() : partitionQuotaWaitTime_;
}
}
/**
*
* Time spent awaiting for partition write quota. Same for each message in response.
*
*
* .google.protobuf.Duration partition_quota_wait_time = 4;
*/
private com.google.protobuf.SingleFieldBuilderV3<
com.google.protobuf.Duration, com.google.protobuf.Duration.Builder, com.google.protobuf.DurationOrBuilder>
getPartitionQuotaWaitTimeFieldBuilder() {
if (partitionQuotaWaitTimeBuilder_ == null) {
partitionQuotaWaitTimeBuilder_ = new com.google.protobuf.SingleFieldBuilderV3<
com.google.protobuf.Duration, com.google.protobuf.Duration.Builder, com.google.protobuf.DurationOrBuilder>(
getPartitionQuotaWaitTime(),
getParentForChildren(),
isClean());
partitionQuotaWaitTime_ = null;
}
return partitionQuotaWaitTimeBuilder_;
}
private com.google.protobuf.Duration topicQuotaWaitTime_;
private com.google.protobuf.SingleFieldBuilderV3<
com.google.protobuf.Duration, com.google.protobuf.Duration.Builder, com.google.protobuf.DurationOrBuilder> topicQuotaWaitTimeBuilder_;
/**
*
* Time spent awaiting for topic write quota. Same for each message in response.
*
*
* .google.protobuf.Duration topic_quota_wait_time = 5;
* @return Whether the topicQuotaWaitTime field is set.
*/
public boolean hasTopicQuotaWaitTime() {
return ((bitField0_ & 0x00000010) != 0);
}
/**
*
* Time spent awaiting for topic write quota. Same for each message in response.
*
*
* .google.protobuf.Duration topic_quota_wait_time = 5;
* @return The topicQuotaWaitTime.
*/
public com.google.protobuf.Duration getTopicQuotaWaitTime() {
if (topicQuotaWaitTimeBuilder_ == null) {
return topicQuotaWaitTime_ == null ? com.google.protobuf.Duration.getDefaultInstance() : topicQuotaWaitTime_;
} else {
return topicQuotaWaitTimeBuilder_.getMessage();
}
}
/**
*
* Time spent awaiting for topic write quota. Same for each message in response.
*
*
* .google.protobuf.Duration topic_quota_wait_time = 5;
*/
public Builder setTopicQuotaWaitTime(com.google.protobuf.Duration value) {
if (topicQuotaWaitTimeBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
topicQuotaWaitTime_ = value;
} else {
topicQuotaWaitTimeBuilder_.setMessage(value);
}
bitField0_ |= 0x00000010;
onChanged();
return this;
}
/**
*
* Time spent awaiting for topic write quota. Same for each message in response.
*
*
* .google.protobuf.Duration topic_quota_wait_time = 5;
*/
public Builder setTopicQuotaWaitTime(
com.google.protobuf.Duration.Builder builderForValue) {
if (topicQuotaWaitTimeBuilder_ == null) {
topicQuotaWaitTime_ = builderForValue.build();
} else {
topicQuotaWaitTimeBuilder_.setMessage(builderForValue.build());
}
bitField0_ |= 0x00000010;
onChanged();
return this;
}
/**
*
* Time spent awaiting for topic write quota. Same for each message in response.
*
*
* .google.protobuf.Duration topic_quota_wait_time = 5;
*/
public Builder mergeTopicQuotaWaitTime(com.google.protobuf.Duration value) {
if (topicQuotaWaitTimeBuilder_ == null) {
if (((bitField0_ & 0x00000010) != 0) &&
topicQuotaWaitTime_ != null &&
topicQuotaWaitTime_ != com.google.protobuf.Duration.getDefaultInstance()) {
getTopicQuotaWaitTimeBuilder().mergeFrom(value);
} else {
topicQuotaWaitTime_ = value;
}
} else {
topicQuotaWaitTimeBuilder_.mergeFrom(value);
}
if (topicQuotaWaitTime_ != null) {
bitField0_ |= 0x00000010;
onChanged();
}
return this;
}
/**
*
* Time spent awaiting for topic write quota. Same for each message in response.
*
*
* .google.protobuf.Duration topic_quota_wait_time = 5;
*/
public Builder clearTopicQuotaWaitTime() {
bitField0_ = (bitField0_ & ~0x00000010);
topicQuotaWaitTime_ = null;
if (topicQuotaWaitTimeBuilder_ != null) {
topicQuotaWaitTimeBuilder_.dispose();
topicQuotaWaitTimeBuilder_ = null;
}
onChanged();
return this;
}
/**
*
* Time spent awaiting for topic write quota. Same for each message in response.
*
*
* .google.protobuf.Duration topic_quota_wait_time = 5;
*/
public com.google.protobuf.Duration.Builder getTopicQuotaWaitTimeBuilder() {
bitField0_ |= 0x00000010;
onChanged();
return getTopicQuotaWaitTimeFieldBuilder().getBuilder();
}
/**
*
* Time spent awaiting for topic write quota. Same for each message in response.
*
*
* .google.protobuf.Duration topic_quota_wait_time = 5;
*/
public com.google.protobuf.DurationOrBuilder getTopicQuotaWaitTimeOrBuilder() {
if (topicQuotaWaitTimeBuilder_ != null) {
return topicQuotaWaitTimeBuilder_.getMessageOrBuilder();
} else {
return topicQuotaWaitTime_ == null ?
com.google.protobuf.Duration.getDefaultInstance() : topicQuotaWaitTime_;
}
}
/**
*
* Time spent awaiting for topic write quota. Same for each message in response.
*
*
* .google.protobuf.Duration topic_quota_wait_time = 5;
*/
private com.google.protobuf.SingleFieldBuilderV3<
com.google.protobuf.Duration, com.google.protobuf.Duration.Builder, com.google.protobuf.DurationOrBuilder>
getTopicQuotaWaitTimeFieldBuilder() {
if (topicQuotaWaitTimeBuilder_ == null) {
topicQuotaWaitTimeBuilder_ = new com.google.protobuf.SingleFieldBuilderV3<
com.google.protobuf.Duration, com.google.protobuf.Duration.Builder, com.google.protobuf.DurationOrBuilder>(
getTopicQuotaWaitTime(),
getParentForChildren(),
isClean());
topicQuotaWaitTime_ = null;
}
return topicQuotaWaitTimeBuilder_;
}
@java.lang.Override
public final Builder setUnknownFields(
final com.google.protobuf.UnknownFieldSet unknownFields) {
return super.setUnknownFields(unknownFields);
}
@java.lang.Override
public final Builder mergeUnknownFields(
final com.google.protobuf.UnknownFieldSet unknownFields) {
return super.mergeUnknownFields(unknownFields);
}
// @@protoc_insertion_point(builder_scope:Ydb.Topic.StreamWriteMessage.WriteResponse.WriteStatistics)
}
// @@protoc_insertion_point(class_scope:Ydb.Topic.StreamWriteMessage.WriteResponse.WriteStatistics)
private static final tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteStatistics DEFAULT_INSTANCE;
static {
DEFAULT_INSTANCE = new tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteStatistics();
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteStatistics getDefaultInstance() {
return DEFAULT_INSTANCE;
}
private static final com.google.protobuf.Parser
PARSER = new com.google.protobuf.AbstractParser() {
@java.lang.Override
public WriteStatistics parsePartialFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
Builder builder = newBuilder();
try {
builder.mergeFrom(input, extensionRegistry);
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.setUnfinishedMessage(builder.buildPartial());
} catch (com.google.protobuf.UninitializedMessageException e) {
throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial());
} catch (java.io.IOException e) {
throw new com.google.protobuf.InvalidProtocolBufferException(e)
.setUnfinishedMessage(builder.buildPartial());
}
return builder.buildPartial();
}
};
public static com.google.protobuf.Parser parser() {
return PARSER;
}
@java.lang.Override
public com.google.protobuf.Parser getParserForType() {
return PARSER;
}
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteStatistics getDefaultInstanceForType() {
return DEFAULT_INSTANCE;
}
}
private int bitField0_;
public static final int ACKS_FIELD_NUMBER = 1;
@SuppressWarnings("serial")
private java.util.List acks_;
/**
*
* Number of acks is equal to number of messages in the corresponding WriteRequests.
*
*
* repeated .Ydb.Topic.StreamWriteMessage.WriteResponse.WriteAck acks = 1;
*/
@java.lang.Override
public java.util.List getAcksList() {
return acks_;
}
/**
*
* Number of acks is equal to number of messages in the corresponding WriteRequests.
*
*
* repeated .Ydb.Topic.StreamWriteMessage.WriteResponse.WriteAck acks = 1;
*/
@java.lang.Override
public java.util.List extends tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAckOrBuilder>
getAcksOrBuilderList() {
return acks_;
}
/**
*
* Number of acks is equal to number of messages in the corresponding WriteRequests.
*
*
* repeated .Ydb.Topic.StreamWriteMessage.WriteResponse.WriteAck acks = 1;
*/
@java.lang.Override
public int getAcksCount() {
return acks_.size();
}
/**
*
* Number of acks is equal to number of messages in the corresponding WriteRequests.
*
*
* repeated .Ydb.Topic.StreamWriteMessage.WriteResponse.WriteAck acks = 1;
*/
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck getAcks(int index) {
return acks_.get(index);
}
/**
*
* Number of acks is equal to number of messages in the corresponding WriteRequests.
*
*
* repeated .Ydb.Topic.StreamWriteMessage.WriteResponse.WriteAck acks = 1;
*/
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAckOrBuilder getAcksOrBuilder(
int index) {
return acks_.get(index);
}
public static final int PARTITION_ID_FIELD_NUMBER = 2;
private long partitionId_ = 0L;
/**
*
* Assigned partition for all client messages inside this batch.
* This actual partition may differ from that returned in InitResponse
* or other WriteResponses in this write session.
*
*
* int64 partition_id = 2;
* @return The partitionId.
*/
@java.lang.Override
public long getPartitionId() {
return partitionId_;
}
public static final int WRITE_STATISTICS_FIELD_NUMBER = 3;
private tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteStatistics writeStatistics_;
/**
*
* Write statistics for this sequence of client messages.
*
*
* .Ydb.Topic.StreamWriteMessage.WriteResponse.WriteStatistics write_statistics = 3;
* @return Whether the writeStatistics field is set.
*/
@java.lang.Override
public boolean hasWriteStatistics() {
return ((bitField0_ & 0x00000001) != 0);
}
/**
*
* Write statistics for this sequence of client messages.
*
*
* .Ydb.Topic.StreamWriteMessage.WriteResponse.WriteStatistics write_statistics = 3;
* @return The writeStatistics.
*/
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteStatistics getWriteStatistics() {
return writeStatistics_ == null ? tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteStatistics.getDefaultInstance() : writeStatistics_;
}
/**
*
* Write statistics for this sequence of client messages.
*
*
* .Ydb.Topic.StreamWriteMessage.WriteResponse.WriteStatistics write_statistics = 3;
*/
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteStatisticsOrBuilder getWriteStatisticsOrBuilder() {
return writeStatistics_ == null ? tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteStatistics.getDefaultInstance() : writeStatistics_;
}
private byte memoizedIsInitialized = -1;
@java.lang.Override
public final boolean isInitialized() {
byte isInitialized = memoizedIsInitialized;
if (isInitialized == 1) return true;
if (isInitialized == 0) return false;
memoizedIsInitialized = 1;
return true;
}
@java.lang.Override
public void writeTo(com.google.protobuf.CodedOutputStream output)
throws java.io.IOException {
for (int i = 0; i < acks_.size(); i++) {
output.writeMessage(1, acks_.get(i));
}
if (partitionId_ != 0L) {
output.writeInt64(2, partitionId_);
}
if (((bitField0_ & 0x00000001) != 0)) {
output.writeMessage(3, getWriteStatistics());
}
getUnknownFields().writeTo(output);
}
@java.lang.Override
public int getSerializedSize() {
int size = memoizedSize;
if (size != -1) return size;
size = 0;
for (int i = 0; i < acks_.size(); i++) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(1, acks_.get(i));
}
if (partitionId_ != 0L) {
size += com.google.protobuf.CodedOutputStream
.computeInt64Size(2, partitionId_);
}
if (((bitField0_ & 0x00000001) != 0)) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(3, getWriteStatistics());
}
size += getUnknownFields().getSerializedSize();
memoizedSize = size;
return size;
}
@java.lang.Override
public boolean equals(final java.lang.Object obj) {
if (obj == this) {
return true;
}
if (!(obj instanceof tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse)) {
return super.equals(obj);
}
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse other = (tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse) obj;
if (!getAcksList()
.equals(other.getAcksList())) return false;
if (getPartitionId()
!= other.getPartitionId()) return false;
if (hasWriteStatistics() != other.hasWriteStatistics()) return false;
if (hasWriteStatistics()) {
if (!getWriteStatistics()
.equals(other.getWriteStatistics())) return false;
}
if (!getUnknownFields().equals(other.getUnknownFields())) return false;
return true;
}
@java.lang.Override
public int hashCode() {
if (memoizedHashCode != 0) {
return memoizedHashCode;
}
int hash = 41;
hash = (19 * hash) + getDescriptor().hashCode();
if (getAcksCount() > 0) {
hash = (37 * hash) + ACKS_FIELD_NUMBER;
hash = (53 * hash) + getAcksList().hashCode();
}
hash = (37 * hash) + PARTITION_ID_FIELD_NUMBER;
hash = (53 * hash) + com.google.protobuf.Internal.hashLong(
getPartitionId());
if (hasWriteStatistics()) {
hash = (37 * hash) + WRITE_STATISTICS_FIELD_NUMBER;
hash = (53 * hash) + getWriteStatistics().hashCode();
}
hash = (29 * hash) + getUnknownFields().hashCode();
memoizedHashCode = hash;
return hash;
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse parseFrom(
java.nio.ByteBuffer data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse parseFrom(
java.nio.ByteBuffer data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse parseFrom(
com.google.protobuf.ByteString data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse parseFrom(
com.google.protobuf.ByteString data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse parseFrom(byte[] data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse parseFrom(
byte[] data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse parseFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse parseFrom(
java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse parseDelimitedFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input);
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse parseDelimitedFrom(
java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse parseFrom(
com.google.protobuf.CodedInputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse parseFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry);
}
@java.lang.Override
public Builder newBuilderForType() { return newBuilder(); }
public static Builder newBuilder() {
return DEFAULT_INSTANCE.toBuilder();
}
public static Builder newBuilder(tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse prototype) {
return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
}
@java.lang.Override
public Builder toBuilder() {
return this == DEFAULT_INSTANCE
? new Builder() : new Builder().mergeFrom(this);
}
@java.lang.Override
protected Builder newBuilderForType(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
Builder builder = new Builder(parent);
return builder;
}
/**
*
* Message that represents acknowledgment for sequence of client messages.
* This sequence is persisted together so write statistics is for messages batch.
*
*
* Protobuf type {@code Ydb.Topic.StreamWriteMessage.WriteResponse}
*/
public static final class Builder extends
com.google.protobuf.GeneratedMessageV3.Builder implements
// @@protoc_insertion_point(builder_implements:Ydb.Topic.StreamWriteMessage.WriteResponse)
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponseOrBuilder {
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_StreamWriteMessage_WriteResponse_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_StreamWriteMessage_WriteResponse_fieldAccessorTable
.ensureFieldAccessorsInitialized(
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.class, tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.Builder.class);
}
// Construct using tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.newBuilder()
private Builder() {
maybeForceBuilderInitialization();
}
private Builder(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
super(parent);
maybeForceBuilderInitialization();
}
private void maybeForceBuilderInitialization() {
if (com.google.protobuf.GeneratedMessageV3
.alwaysUseFieldBuilders) {
getAcksFieldBuilder();
getWriteStatisticsFieldBuilder();
}
}
@java.lang.Override
public Builder clear() {
super.clear();
bitField0_ = 0;
if (acksBuilder_ == null) {
acks_ = java.util.Collections.emptyList();
} else {
acks_ = null;
acksBuilder_.clear();
}
bitField0_ = (bitField0_ & ~0x00000001);
partitionId_ = 0L;
writeStatistics_ = null;
if (writeStatisticsBuilder_ != null) {
writeStatisticsBuilder_.dispose();
writeStatisticsBuilder_ = null;
}
return this;
}
@java.lang.Override
public com.google.protobuf.Descriptors.Descriptor
getDescriptorForType() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_StreamWriteMessage_WriteResponse_descriptor;
}
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse getDefaultInstanceForType() {
return tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.getDefaultInstance();
}
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse build() {
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse result = buildPartial();
if (!result.isInitialized()) {
throw newUninitializedMessageException(result);
}
return result;
}
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse buildPartial() {
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse result = new tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse(this);
buildPartialRepeatedFields(result);
if (bitField0_ != 0) { buildPartial0(result); }
onBuilt();
return result;
}
private void buildPartialRepeatedFields(tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse result) {
if (acksBuilder_ == null) {
if (((bitField0_ & 0x00000001) != 0)) {
acks_ = java.util.Collections.unmodifiableList(acks_);
bitField0_ = (bitField0_ & ~0x00000001);
}
result.acks_ = acks_;
} else {
result.acks_ = acksBuilder_.build();
}
}
private void buildPartial0(tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse result) {
int from_bitField0_ = bitField0_;
if (((from_bitField0_ & 0x00000002) != 0)) {
result.partitionId_ = partitionId_;
}
int to_bitField0_ = 0;
if (((from_bitField0_ & 0x00000004) != 0)) {
result.writeStatistics_ = writeStatisticsBuilder_ == null
? writeStatistics_
: writeStatisticsBuilder_.build();
to_bitField0_ |= 0x00000001;
}
result.bitField0_ |= to_bitField0_;
}
@java.lang.Override
public Builder clone() {
return super.clone();
}
@java.lang.Override
public Builder setField(
com.google.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) {
return super.setField(field, value);
}
@java.lang.Override
public Builder clearField(
com.google.protobuf.Descriptors.FieldDescriptor field) {
return super.clearField(field);
}
@java.lang.Override
public Builder clearOneof(
com.google.protobuf.Descriptors.OneofDescriptor oneof) {
return super.clearOneof(oneof);
}
@java.lang.Override
public Builder setRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
int index, java.lang.Object value) {
return super.setRepeatedField(field, index, value);
}
@java.lang.Override
public Builder addRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) {
return super.addRepeatedField(field, value);
}
@java.lang.Override
public Builder mergeFrom(com.google.protobuf.Message other) {
if (other instanceof tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse) {
return mergeFrom((tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse)other);
} else {
super.mergeFrom(other);
return this;
}
}
public Builder mergeFrom(tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse other) {
if (other == tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.getDefaultInstance()) return this;
if (acksBuilder_ == null) {
if (!other.acks_.isEmpty()) {
if (acks_.isEmpty()) {
acks_ = other.acks_;
bitField0_ = (bitField0_ & ~0x00000001);
} else {
ensureAcksIsMutable();
acks_.addAll(other.acks_);
}
onChanged();
}
} else {
if (!other.acks_.isEmpty()) {
if (acksBuilder_.isEmpty()) {
acksBuilder_.dispose();
acksBuilder_ = null;
acks_ = other.acks_;
bitField0_ = (bitField0_ & ~0x00000001);
acksBuilder_ =
com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders ?
getAcksFieldBuilder() : null;
} else {
acksBuilder_.addAllMessages(other.acks_);
}
}
}
if (other.getPartitionId() != 0L) {
setPartitionId(other.getPartitionId());
}
if (other.hasWriteStatistics()) {
mergeWriteStatistics(other.getWriteStatistics());
}
this.mergeUnknownFields(other.getUnknownFields());
onChanged();
return this;
}
@java.lang.Override
public final boolean isInitialized() {
return true;
}
@java.lang.Override
public Builder mergeFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
if (extensionRegistry == null) {
throw new java.lang.NullPointerException();
}
try {
boolean done = false;
while (!done) {
int tag = input.readTag();
switch (tag) {
case 0:
done = true;
break;
case 10: {
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck m =
input.readMessage(
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.parser(),
extensionRegistry);
if (acksBuilder_ == null) {
ensureAcksIsMutable();
acks_.add(m);
} else {
acksBuilder_.addMessage(m);
}
break;
} // case 10
case 16: {
partitionId_ = input.readInt64();
bitField0_ |= 0x00000002;
break;
} // case 16
case 26: {
input.readMessage(
getWriteStatisticsFieldBuilder().getBuilder(),
extensionRegistry);
bitField0_ |= 0x00000004;
break;
} // case 26
default: {
if (!super.parseUnknownField(input, extensionRegistry, tag)) {
done = true; // was an endgroup tag
}
break;
} // default:
} // switch (tag)
} // while (!done)
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.unwrapIOException();
} finally {
onChanged();
} // finally
return this;
}
private int bitField0_;
private java.util.List acks_ =
java.util.Collections.emptyList();
private void ensureAcksIsMutable() {
if (!((bitField0_ & 0x00000001) != 0)) {
acks_ = new java.util.ArrayList(acks_);
bitField0_ |= 0x00000001;
}
}
private com.google.protobuf.RepeatedFieldBuilderV3<
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck, tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Builder, tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAckOrBuilder> acksBuilder_;
/**
*
* Number of acks is equal to number of messages in the corresponding WriteRequests.
*
*
* repeated .Ydb.Topic.StreamWriteMessage.WriteResponse.WriteAck acks = 1;
*/
public java.util.List getAcksList() {
if (acksBuilder_ == null) {
return java.util.Collections.unmodifiableList(acks_);
} else {
return acksBuilder_.getMessageList();
}
}
/**
*
* Number of acks is equal to number of messages in the corresponding WriteRequests.
*
*
* repeated .Ydb.Topic.StreamWriteMessage.WriteResponse.WriteAck acks = 1;
*/
public int getAcksCount() {
if (acksBuilder_ == null) {
return acks_.size();
} else {
return acksBuilder_.getCount();
}
}
/**
*
* Number of acks is equal to number of messages in the corresponding WriteRequests.
*
*
* repeated .Ydb.Topic.StreamWriteMessage.WriteResponse.WriteAck acks = 1;
*/
public tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck getAcks(int index) {
if (acksBuilder_ == null) {
return acks_.get(index);
} else {
return acksBuilder_.getMessage(index);
}
}
/**
*
* Number of acks is equal to number of messages in the corresponding WriteRequests.
*
*
* repeated .Ydb.Topic.StreamWriteMessage.WriteResponse.WriteAck acks = 1;
*/
public Builder setAcks(
int index, tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck value) {
if (acksBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
ensureAcksIsMutable();
acks_.set(index, value);
onChanged();
} else {
acksBuilder_.setMessage(index, value);
}
return this;
}
/**
*
* Number of acks is equal to number of messages in the corresponding WriteRequests.
*
*
* repeated .Ydb.Topic.StreamWriteMessage.WriteResponse.WriteAck acks = 1;
*/
public Builder setAcks(
int index, tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Builder builderForValue) {
if (acksBuilder_ == null) {
ensureAcksIsMutable();
acks_.set(index, builderForValue.build());
onChanged();
} else {
acksBuilder_.setMessage(index, builderForValue.build());
}
return this;
}
/**
*
* Number of acks is equal to number of messages in the corresponding WriteRequests.
*
*
* repeated .Ydb.Topic.StreamWriteMessage.WriteResponse.WriteAck acks = 1;
*/
public Builder addAcks(tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck value) {
if (acksBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
ensureAcksIsMutable();
acks_.add(value);
onChanged();
} else {
acksBuilder_.addMessage(value);
}
return this;
}
/**
*
* Number of acks is equal to number of messages in the corresponding WriteRequests.
*
*
* repeated .Ydb.Topic.StreamWriteMessage.WriteResponse.WriteAck acks = 1;
*/
public Builder addAcks(
int index, tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck value) {
if (acksBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
ensureAcksIsMutable();
acks_.add(index, value);
onChanged();
} else {
acksBuilder_.addMessage(index, value);
}
return this;
}
/**
*
* Number of acks is equal to number of messages in the corresponding WriteRequests.
*
*
* repeated .Ydb.Topic.StreamWriteMessage.WriteResponse.WriteAck acks = 1;
*/
public Builder addAcks(
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Builder builderForValue) {
if (acksBuilder_ == null) {
ensureAcksIsMutable();
acks_.add(builderForValue.build());
onChanged();
} else {
acksBuilder_.addMessage(builderForValue.build());
}
return this;
}
/**
*
* Number of acks is equal to number of messages in the corresponding WriteRequests.
*
*
* repeated .Ydb.Topic.StreamWriteMessage.WriteResponse.WriteAck acks = 1;
*/
public Builder addAcks(
int index, tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Builder builderForValue) {
if (acksBuilder_ == null) {
ensureAcksIsMutable();
acks_.add(index, builderForValue.build());
onChanged();
} else {
acksBuilder_.addMessage(index, builderForValue.build());
}
return this;
}
/**
*
* Number of acks is equal to number of messages in the corresponding WriteRequests.
*
*
* repeated .Ydb.Topic.StreamWriteMessage.WriteResponse.WriteAck acks = 1;
*/
public Builder addAllAcks(
java.lang.Iterable extends tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck> values) {
if (acksBuilder_ == null) {
ensureAcksIsMutable();
com.google.protobuf.AbstractMessageLite.Builder.addAll(
values, acks_);
onChanged();
} else {
acksBuilder_.addAllMessages(values);
}
return this;
}
/**
*
* Number of acks is equal to number of messages in the corresponding WriteRequests.
*
*
* repeated .Ydb.Topic.StreamWriteMessage.WriteResponse.WriteAck acks = 1;
*/
public Builder clearAcks() {
if (acksBuilder_ == null) {
acks_ = java.util.Collections.emptyList();
bitField0_ = (bitField0_ & ~0x00000001);
onChanged();
} else {
acksBuilder_.clear();
}
return this;
}
/**
*
* Number of acks is equal to number of messages in the corresponding WriteRequests.
*
*
* repeated .Ydb.Topic.StreamWriteMessage.WriteResponse.WriteAck acks = 1;
*/
public Builder removeAcks(int index) {
if (acksBuilder_ == null) {
ensureAcksIsMutable();
acks_.remove(index);
onChanged();
} else {
acksBuilder_.remove(index);
}
return this;
}
/**
*
* Number of acks is equal to number of messages in the corresponding WriteRequests.
*
*
* repeated .Ydb.Topic.StreamWriteMessage.WriteResponse.WriteAck acks = 1;
*/
public tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Builder getAcksBuilder(
int index) {
return getAcksFieldBuilder().getBuilder(index);
}
/**
*
* Number of acks is equal to number of messages in the corresponding WriteRequests.
*
*
* repeated .Ydb.Topic.StreamWriteMessage.WriteResponse.WriteAck acks = 1;
*/
public tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAckOrBuilder getAcksOrBuilder(
int index) {
if (acksBuilder_ == null) {
return acks_.get(index); } else {
return acksBuilder_.getMessageOrBuilder(index);
}
}
/**
*
* Number of acks is equal to number of messages in the corresponding WriteRequests.
*
*
* repeated .Ydb.Topic.StreamWriteMessage.WriteResponse.WriteAck acks = 1;
*/
public java.util.List extends tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAckOrBuilder>
getAcksOrBuilderList() {
if (acksBuilder_ != null) {
return acksBuilder_.getMessageOrBuilderList();
} else {
return java.util.Collections.unmodifiableList(acks_);
}
}
/**
*
* Number of acks is equal to number of messages in the corresponding WriteRequests.
*
*
* repeated .Ydb.Topic.StreamWriteMessage.WriteResponse.WriteAck acks = 1;
*/
public tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Builder addAcksBuilder() {
return getAcksFieldBuilder().addBuilder(
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.getDefaultInstance());
}
/**
*
* Number of acks is equal to number of messages in the corresponding WriteRequests.
*
*
* repeated .Ydb.Topic.StreamWriteMessage.WriteResponse.WriteAck acks = 1;
*/
public tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Builder addAcksBuilder(
int index) {
return getAcksFieldBuilder().addBuilder(
index, tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.getDefaultInstance());
}
/**
*
* Number of acks is equal to number of messages in the corresponding WriteRequests.
*
*
* repeated .Ydb.Topic.StreamWriteMessage.WriteResponse.WriteAck acks = 1;
*/
public java.util.List
getAcksBuilderList() {
return getAcksFieldBuilder().getBuilderList();
}
private com.google.protobuf.RepeatedFieldBuilderV3<
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck, tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Builder, tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAckOrBuilder>
getAcksFieldBuilder() {
if (acksBuilder_ == null) {
acksBuilder_ = new com.google.protobuf.RepeatedFieldBuilderV3<
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck, tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAck.Builder, tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteAckOrBuilder>(
acks_,
((bitField0_ & 0x00000001) != 0),
getParentForChildren(),
isClean());
acks_ = null;
}
return acksBuilder_;
}
private long partitionId_ ;
/**
*
* Assigned partition for all client messages inside this batch.
* This actual partition may differ from that returned in InitResponse
* or other WriteResponses in this write session.
*
*
* int64 partition_id = 2;
* @return The partitionId.
*/
@java.lang.Override
public long getPartitionId() {
return partitionId_;
}
/**
*
* Assigned partition for all client messages inside this batch.
* This actual partition may differ from that returned in InitResponse
* or other WriteResponses in this write session.
*
*
* int64 partition_id = 2;
* @param value The partitionId to set.
* @return This builder for chaining.
*/
public Builder setPartitionId(long value) {
partitionId_ = value;
bitField0_ |= 0x00000002;
onChanged();
return this;
}
/**
*
* Assigned partition for all client messages inside this batch.
* This actual partition may differ from that returned in InitResponse
* or other WriteResponses in this write session.
*
*
* int64 partition_id = 2;
* @return This builder for chaining.
*/
public Builder clearPartitionId() {
bitField0_ = (bitField0_ & ~0x00000002);
partitionId_ = 0L;
onChanged();
return this;
}
private tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteStatistics writeStatistics_;
private com.google.protobuf.SingleFieldBuilderV3<
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteStatistics, tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteStatistics.Builder, tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteStatisticsOrBuilder> writeStatisticsBuilder_;
/**
*
* Write statistics for this sequence of client messages.
*
*
* .Ydb.Topic.StreamWriteMessage.WriteResponse.WriteStatistics write_statistics = 3;
* @return Whether the writeStatistics field is set.
*/
public boolean hasWriteStatistics() {
return ((bitField0_ & 0x00000004) != 0);
}
/**
*
* Write statistics for this sequence of client messages.
*
*
* .Ydb.Topic.StreamWriteMessage.WriteResponse.WriteStatistics write_statistics = 3;
* @return The writeStatistics.
*/
public tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteStatistics getWriteStatistics() {
if (writeStatisticsBuilder_ == null) {
return writeStatistics_ == null ? tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteStatistics.getDefaultInstance() : writeStatistics_;
} else {
return writeStatisticsBuilder_.getMessage();
}
}
/**
*
* Write statistics for this sequence of client messages.
*
*
* .Ydb.Topic.StreamWriteMessage.WriteResponse.WriteStatistics write_statistics = 3;
*/
public Builder setWriteStatistics(tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteStatistics value) {
if (writeStatisticsBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
writeStatistics_ = value;
} else {
writeStatisticsBuilder_.setMessage(value);
}
bitField0_ |= 0x00000004;
onChanged();
return this;
}
/**
*
* Write statistics for this sequence of client messages.
*
*
* .Ydb.Topic.StreamWriteMessage.WriteResponse.WriteStatistics write_statistics = 3;
*/
public Builder setWriteStatistics(
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteStatistics.Builder builderForValue) {
if (writeStatisticsBuilder_ == null) {
writeStatistics_ = builderForValue.build();
} else {
writeStatisticsBuilder_.setMessage(builderForValue.build());
}
bitField0_ |= 0x00000004;
onChanged();
return this;
}
/**
*
* Write statistics for this sequence of client messages.
*
*
* .Ydb.Topic.StreamWriteMessage.WriteResponse.WriteStatistics write_statistics = 3;
*/
public Builder mergeWriteStatistics(tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteStatistics value) {
if (writeStatisticsBuilder_ == null) {
if (((bitField0_ & 0x00000004) != 0) &&
writeStatistics_ != null &&
writeStatistics_ != tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteStatistics.getDefaultInstance()) {
getWriteStatisticsBuilder().mergeFrom(value);
} else {
writeStatistics_ = value;
}
} else {
writeStatisticsBuilder_.mergeFrom(value);
}
if (writeStatistics_ != null) {
bitField0_ |= 0x00000004;
onChanged();
}
return this;
}
/**
*
* Write statistics for this sequence of client messages.
*
*
* .Ydb.Topic.StreamWriteMessage.WriteResponse.WriteStatistics write_statistics = 3;
*/
public Builder clearWriteStatistics() {
bitField0_ = (bitField0_ & ~0x00000004);
writeStatistics_ = null;
if (writeStatisticsBuilder_ != null) {
writeStatisticsBuilder_.dispose();
writeStatisticsBuilder_ = null;
}
onChanged();
return this;
}
/**
*
* Write statistics for this sequence of client messages.
*
*
* .Ydb.Topic.StreamWriteMessage.WriteResponse.WriteStatistics write_statistics = 3;
*/
public tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteStatistics.Builder getWriteStatisticsBuilder() {
bitField0_ |= 0x00000004;
onChanged();
return getWriteStatisticsFieldBuilder().getBuilder();
}
/**
*
* Write statistics for this sequence of client messages.
*
*
* .Ydb.Topic.StreamWriteMessage.WriteResponse.WriteStatistics write_statistics = 3;
*/
public tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteStatisticsOrBuilder getWriteStatisticsOrBuilder() {
if (writeStatisticsBuilder_ != null) {
return writeStatisticsBuilder_.getMessageOrBuilder();
} else {
return writeStatistics_ == null ?
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteStatistics.getDefaultInstance() : writeStatistics_;
}
}
/**
*
* Write statistics for this sequence of client messages.
*
*
* .Ydb.Topic.StreamWriteMessage.WriteResponse.WriteStatistics write_statistics = 3;
*/
private com.google.protobuf.SingleFieldBuilderV3<
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteStatistics, tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteStatistics.Builder, tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteStatisticsOrBuilder>
getWriteStatisticsFieldBuilder() {
if (writeStatisticsBuilder_ == null) {
writeStatisticsBuilder_ = new com.google.protobuf.SingleFieldBuilderV3<
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteStatistics, tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteStatistics.Builder, tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse.WriteStatisticsOrBuilder>(
getWriteStatistics(),
getParentForChildren(),
isClean());
writeStatistics_ = null;
}
return writeStatisticsBuilder_;
}
@java.lang.Override
public final Builder setUnknownFields(
final com.google.protobuf.UnknownFieldSet unknownFields) {
return super.setUnknownFields(unknownFields);
}
@java.lang.Override
public final Builder mergeUnknownFields(
final com.google.protobuf.UnknownFieldSet unknownFields) {
return super.mergeUnknownFields(unknownFields);
}
// @@protoc_insertion_point(builder_scope:Ydb.Topic.StreamWriteMessage.WriteResponse)
}
// @@protoc_insertion_point(class_scope:Ydb.Topic.StreamWriteMessage.WriteResponse)
private static final tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse DEFAULT_INSTANCE;
static {
DEFAULT_INSTANCE = new tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse();
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse getDefaultInstance() {
return DEFAULT_INSTANCE;
}
private static final com.google.protobuf.Parser
PARSER = new com.google.protobuf.AbstractParser() {
@java.lang.Override
public WriteResponse parsePartialFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
Builder builder = newBuilder();
try {
builder.mergeFrom(input, extensionRegistry);
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.setUnfinishedMessage(builder.buildPartial());
} catch (com.google.protobuf.UninitializedMessageException e) {
throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial());
} catch (java.io.IOException e) {
throw new com.google.protobuf.InvalidProtocolBufferException(e)
.setUnfinishedMessage(builder.buildPartial());
}
return builder.buildPartial();
}
};
public static com.google.protobuf.Parser parser() {
return PARSER;
}
@java.lang.Override
public com.google.protobuf.Parser getParserForType() {
return PARSER;
}
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.WriteResponse getDefaultInstanceForType() {
return DEFAULT_INSTANCE;
}
}
private byte memoizedIsInitialized = -1;
@java.lang.Override
public final boolean isInitialized() {
byte isInitialized = memoizedIsInitialized;
if (isInitialized == 1) return true;
if (isInitialized == 0) return false;
memoizedIsInitialized = 1;
return true;
}
@java.lang.Override
public void writeTo(com.google.protobuf.CodedOutputStream output)
throws java.io.IOException {
getUnknownFields().writeTo(output);
}
@java.lang.Override
public int getSerializedSize() {
int size = memoizedSize;
if (size != -1) return size;
size = 0;
size += getUnknownFields().getSerializedSize();
memoizedSize = size;
return size;
}
@java.lang.Override
public boolean equals(final java.lang.Object obj) {
if (obj == this) {
return true;
}
if (!(obj instanceof tech.ydb.proto.topic.YdbTopic.StreamWriteMessage)) {
return super.equals(obj);
}
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage other = (tech.ydb.proto.topic.YdbTopic.StreamWriteMessage) obj;
if (!getUnknownFields().equals(other.getUnknownFields())) return false;
return true;
}
@java.lang.Override
public int hashCode() {
if (memoizedHashCode != 0) {
return memoizedHashCode;
}
int hash = 41;
hash = (19 * hash) + getDescriptor().hashCode();
hash = (29 * hash) + getUnknownFields().hashCode();
memoizedHashCode = hash;
return hash;
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage parseFrom(
java.nio.ByteBuffer data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage parseFrom(
java.nio.ByteBuffer data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage parseFrom(
com.google.protobuf.ByteString data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage parseFrom(
com.google.protobuf.ByteString data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage parseFrom(byte[] data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage parseFrom(
byte[] data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage parseFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage parseFrom(
java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage parseDelimitedFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input);
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage parseDelimitedFrom(
java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage parseFrom(
com.google.protobuf.CodedInputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage parseFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry);
}
@java.lang.Override
public Builder newBuilderForType() { return newBuilder(); }
public static Builder newBuilder() {
return DEFAULT_INSTANCE.toBuilder();
}
public static Builder newBuilder(tech.ydb.proto.topic.YdbTopic.StreamWriteMessage prototype) {
return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
}
@java.lang.Override
public Builder toBuilder() {
return this == DEFAULT_INSTANCE
? new Builder() : new Builder().mergeFrom(this);
}
@java.lang.Override
protected Builder newBuilderForType(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
Builder builder = new Builder(parent);
return builder;
}
/**
*
* Messages for bidirectional streaming rpc StreamWrite
*
*
* Protobuf type {@code Ydb.Topic.StreamWriteMessage}
*/
public static final class Builder extends
com.google.protobuf.GeneratedMessageV3.Builder implements
// @@protoc_insertion_point(builder_implements:Ydb.Topic.StreamWriteMessage)
tech.ydb.proto.topic.YdbTopic.StreamWriteMessageOrBuilder {
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_StreamWriteMessage_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_StreamWriteMessage_fieldAccessorTable
.ensureFieldAccessorsInitialized(
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.class, tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.Builder.class);
}
// Construct using tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.newBuilder()
private Builder() {
}
private Builder(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
super(parent);
}
@java.lang.Override
public Builder clear() {
super.clear();
return this;
}
@java.lang.Override
public com.google.protobuf.Descriptors.Descriptor
getDescriptorForType() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_StreamWriteMessage_descriptor;
}
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamWriteMessage getDefaultInstanceForType() {
return tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.getDefaultInstance();
}
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamWriteMessage build() {
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage result = buildPartial();
if (!result.isInitialized()) {
throw newUninitializedMessageException(result);
}
return result;
}
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamWriteMessage buildPartial() {
tech.ydb.proto.topic.YdbTopic.StreamWriteMessage result = new tech.ydb.proto.topic.YdbTopic.StreamWriteMessage(this);
onBuilt();
return result;
}
@java.lang.Override
public Builder clone() {
return super.clone();
}
@java.lang.Override
public Builder setField(
com.google.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) {
return super.setField(field, value);
}
@java.lang.Override
public Builder clearField(
com.google.protobuf.Descriptors.FieldDescriptor field) {
return super.clearField(field);
}
@java.lang.Override
public Builder clearOneof(
com.google.protobuf.Descriptors.OneofDescriptor oneof) {
return super.clearOneof(oneof);
}
@java.lang.Override
public Builder setRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
int index, java.lang.Object value) {
return super.setRepeatedField(field, index, value);
}
@java.lang.Override
public Builder addRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) {
return super.addRepeatedField(field, value);
}
@java.lang.Override
public Builder mergeFrom(com.google.protobuf.Message other) {
if (other instanceof tech.ydb.proto.topic.YdbTopic.StreamWriteMessage) {
return mergeFrom((tech.ydb.proto.topic.YdbTopic.StreamWriteMessage)other);
} else {
super.mergeFrom(other);
return this;
}
}
public Builder mergeFrom(tech.ydb.proto.topic.YdbTopic.StreamWriteMessage other) {
if (other == tech.ydb.proto.topic.YdbTopic.StreamWriteMessage.getDefaultInstance()) return this;
this.mergeUnknownFields(other.getUnknownFields());
onChanged();
return this;
}
@java.lang.Override
public final boolean isInitialized() {
return true;
}
@java.lang.Override
public Builder mergeFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
if (extensionRegistry == null) {
throw new java.lang.NullPointerException();
}
try {
boolean done = false;
while (!done) {
int tag = input.readTag();
switch (tag) {
case 0:
done = true;
break;
default: {
if (!super.parseUnknownField(input, extensionRegistry, tag)) {
done = true; // was an endgroup tag
}
break;
} // default:
} // switch (tag)
} // while (!done)
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.unwrapIOException();
} finally {
onChanged();
} // finally
return this;
}
@java.lang.Override
public final Builder setUnknownFields(
final com.google.protobuf.UnknownFieldSet unknownFields) {
return super.setUnknownFields(unknownFields);
}
@java.lang.Override
public final Builder mergeUnknownFields(
final com.google.protobuf.UnknownFieldSet unknownFields) {
return super.mergeUnknownFields(unknownFields);
}
// @@protoc_insertion_point(builder_scope:Ydb.Topic.StreamWriteMessage)
}
// @@protoc_insertion_point(class_scope:Ydb.Topic.StreamWriteMessage)
private static final tech.ydb.proto.topic.YdbTopic.StreamWriteMessage DEFAULT_INSTANCE;
static {
DEFAULT_INSTANCE = new tech.ydb.proto.topic.YdbTopic.StreamWriteMessage();
}
public static tech.ydb.proto.topic.YdbTopic.StreamWriteMessage getDefaultInstance() {
return DEFAULT_INSTANCE;
}
private static final com.google.protobuf.Parser
PARSER = new com.google.protobuf.AbstractParser() {
@java.lang.Override
public StreamWriteMessage parsePartialFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
Builder builder = newBuilder();
try {
builder.mergeFrom(input, extensionRegistry);
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.setUnfinishedMessage(builder.buildPartial());
} catch (com.google.protobuf.UninitializedMessageException e) {
throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial());
} catch (java.io.IOException e) {
throw new com.google.protobuf.InvalidProtocolBufferException(e)
.setUnfinishedMessage(builder.buildPartial());
}
return builder.buildPartial();
}
};
public static com.google.protobuf.Parser parser() {
return PARSER;
}
@java.lang.Override
public com.google.protobuf.Parser getParserForType() {
return PARSER;
}
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamWriteMessage getDefaultInstanceForType() {
return DEFAULT_INSTANCE;
}
}
public interface StreamReadMessageOrBuilder extends
// @@protoc_insertion_point(interface_extends:Ydb.Topic.StreamReadMessage)
com.google.protobuf.MessageOrBuilder {
}
/**
*
* Messages for bidirectional streaming rpc StreamRead
*
*
* Protobuf type {@code Ydb.Topic.StreamReadMessage}
*/
public static final class StreamReadMessage extends
com.google.protobuf.GeneratedMessageV3 implements
// @@protoc_insertion_point(message_implements:Ydb.Topic.StreamReadMessage)
StreamReadMessageOrBuilder {
private static final long serialVersionUID = 0L;
// Use StreamReadMessage.newBuilder() to construct.
private StreamReadMessage(com.google.protobuf.GeneratedMessageV3.Builder> builder) {
super(builder);
}
private StreamReadMessage() {
}
@java.lang.Override
@SuppressWarnings({"unused"})
protected java.lang.Object newInstance(
UnusedPrivateParameter unused) {
return new StreamReadMessage();
}
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_StreamReadMessage_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_StreamReadMessage_fieldAccessorTable
.ensureFieldAccessorsInitialized(
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.class, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.Builder.class);
}
public interface PartitionSessionOrBuilder extends
// @@protoc_insertion_point(interface_extends:Ydb.Topic.StreamReadMessage.PartitionSession)
com.google.protobuf.MessageOrBuilder {
/**
*
* Identifier of partition session. Unique inside one RPC call.
*
*
* int64 partition_session_id = 1;
* @return The partitionSessionId.
*/
long getPartitionSessionId();
/**
*
* Topic path of partition.
*
*
* string path = 2;
* @return The path.
*/
java.lang.String getPath();
/**
*
* Topic path of partition.
*
*
* string path = 2;
* @return The bytes for path.
*/
com.google.protobuf.ByteString
getPathBytes();
/**
*
* Partition identifier.
*
*
* int64 partition_id = 3;
* @return The partitionId.
*/
long getPartitionId();
}
/**
*
* Within a StreamRead session delivered messages are separated by partition.
* Reads from a single partition are represented by a partition session.
*
*
* Protobuf type {@code Ydb.Topic.StreamReadMessage.PartitionSession}
*/
public static final class PartitionSession extends
com.google.protobuf.GeneratedMessageV3 implements
// @@protoc_insertion_point(message_implements:Ydb.Topic.StreamReadMessage.PartitionSession)
PartitionSessionOrBuilder {
private static final long serialVersionUID = 0L;
// Use PartitionSession.newBuilder() to construct.
private PartitionSession(com.google.protobuf.GeneratedMessageV3.Builder> builder) {
super(builder);
}
private PartitionSession() {
path_ = "";
}
@java.lang.Override
@SuppressWarnings({"unused"})
protected java.lang.Object newInstance(
UnusedPrivateParameter unused) {
return new PartitionSession();
}
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_StreamReadMessage_PartitionSession_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_StreamReadMessage_PartitionSession_fieldAccessorTable
.ensureFieldAccessorsInitialized(
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.PartitionSession.class, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.PartitionSession.Builder.class);
}
public static final int PARTITION_SESSION_ID_FIELD_NUMBER = 1;
private long partitionSessionId_ = 0L;
/**
*
* Identifier of partition session. Unique inside one RPC call.
*
*
* int64 partition_session_id = 1;
* @return The partitionSessionId.
*/
@java.lang.Override
public long getPartitionSessionId() {
return partitionSessionId_;
}
public static final int PATH_FIELD_NUMBER = 2;
@SuppressWarnings("serial")
private volatile java.lang.Object path_ = "";
/**
*
* Topic path of partition.
*
*
* string path = 2;
* @return The path.
*/
@java.lang.Override
public java.lang.String getPath() {
java.lang.Object ref = path_;
if (ref instanceof java.lang.String) {
return (java.lang.String) ref;
} else {
com.google.protobuf.ByteString bs =
(com.google.protobuf.ByteString) ref;
java.lang.String s = bs.toStringUtf8();
path_ = s;
return s;
}
}
/**
*
* Topic path of partition.
*
*
* string path = 2;
* @return The bytes for path.
*/
@java.lang.Override
public com.google.protobuf.ByteString
getPathBytes() {
java.lang.Object ref = path_;
if (ref instanceof java.lang.String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
path_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
public static final int PARTITION_ID_FIELD_NUMBER = 3;
private long partitionId_ = 0L;
/**
*
* Partition identifier.
*
*
* int64 partition_id = 3;
* @return The partitionId.
*/
@java.lang.Override
public long getPartitionId() {
return partitionId_;
}
private byte memoizedIsInitialized = -1;
@java.lang.Override
public final boolean isInitialized() {
byte isInitialized = memoizedIsInitialized;
if (isInitialized == 1) return true;
if (isInitialized == 0) return false;
memoizedIsInitialized = 1;
return true;
}
@java.lang.Override
public void writeTo(com.google.protobuf.CodedOutputStream output)
throws java.io.IOException {
if (partitionSessionId_ != 0L) {
output.writeInt64(1, partitionSessionId_);
}
if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(path_)) {
com.google.protobuf.GeneratedMessageV3.writeString(output, 2, path_);
}
if (partitionId_ != 0L) {
output.writeInt64(3, partitionId_);
}
getUnknownFields().writeTo(output);
}
@java.lang.Override
public int getSerializedSize() {
int size = memoizedSize;
if (size != -1) return size;
size = 0;
if (partitionSessionId_ != 0L) {
size += com.google.protobuf.CodedOutputStream
.computeInt64Size(1, partitionSessionId_);
}
if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(path_)) {
size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, path_);
}
if (partitionId_ != 0L) {
size += com.google.protobuf.CodedOutputStream
.computeInt64Size(3, partitionId_);
}
size += getUnknownFields().getSerializedSize();
memoizedSize = size;
return size;
}
@java.lang.Override
public boolean equals(final java.lang.Object obj) {
if (obj == this) {
return true;
}
if (!(obj instanceof tech.ydb.proto.topic.YdbTopic.StreamReadMessage.PartitionSession)) {
return super.equals(obj);
}
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.PartitionSession other = (tech.ydb.proto.topic.YdbTopic.StreamReadMessage.PartitionSession) obj;
if (getPartitionSessionId()
!= other.getPartitionSessionId()) return false;
if (!getPath()
.equals(other.getPath())) return false;
if (getPartitionId()
!= other.getPartitionId()) return false;
if (!getUnknownFields().equals(other.getUnknownFields())) return false;
return true;
}
@java.lang.Override
public int hashCode() {
if (memoizedHashCode != 0) {
return memoizedHashCode;
}
int hash = 41;
hash = (19 * hash) + getDescriptor().hashCode();
hash = (37 * hash) + PARTITION_SESSION_ID_FIELD_NUMBER;
hash = (53 * hash) + com.google.protobuf.Internal.hashLong(
getPartitionSessionId());
hash = (37 * hash) + PATH_FIELD_NUMBER;
hash = (53 * hash) + getPath().hashCode();
hash = (37 * hash) + PARTITION_ID_FIELD_NUMBER;
hash = (53 * hash) + com.google.protobuf.Internal.hashLong(
getPartitionId());
hash = (29 * hash) + getUnknownFields().hashCode();
memoizedHashCode = hash;
return hash;
}
public static tech.ydb.proto.topic.YdbTopic.StreamReadMessage.PartitionSession parseFrom(
java.nio.ByteBuffer data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static tech.ydb.proto.topic.YdbTopic.StreamReadMessage.PartitionSession parseFrom(
java.nio.ByteBuffer data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.StreamReadMessage.PartitionSession parseFrom(
com.google.protobuf.ByteString data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static tech.ydb.proto.topic.YdbTopic.StreamReadMessage.PartitionSession parseFrom(
com.google.protobuf.ByteString data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.StreamReadMessage.PartitionSession parseFrom(byte[] data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static tech.ydb.proto.topic.YdbTopic.StreamReadMessage.PartitionSession parseFrom(
byte[] data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.StreamReadMessage.PartitionSession parseFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static tech.ydb.proto.topic.YdbTopic.StreamReadMessage.PartitionSession parseFrom(
java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.StreamReadMessage.PartitionSession parseDelimitedFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input);
}
public static tech.ydb.proto.topic.YdbTopic.StreamReadMessage.PartitionSession parseDelimitedFrom(
java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.StreamReadMessage.PartitionSession parseFrom(
com.google.protobuf.CodedInputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static tech.ydb.proto.topic.YdbTopic.StreamReadMessage.PartitionSession parseFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry);
}
@java.lang.Override
public Builder newBuilderForType() { return newBuilder(); }
public static Builder newBuilder() {
return DEFAULT_INSTANCE.toBuilder();
}
public static Builder newBuilder(tech.ydb.proto.topic.YdbTopic.StreamReadMessage.PartitionSession prototype) {
return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
}
@java.lang.Override
public Builder toBuilder() {
return this == DEFAULT_INSTANCE
? new Builder() : new Builder().mergeFrom(this);
}
@java.lang.Override
protected Builder newBuilderForType(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
Builder builder = new Builder(parent);
return builder;
}
/**
*
* Within a StreamRead session delivered messages are separated by partition.
* Reads from a single partition are represented by a partition session.
*
*
* Protobuf type {@code Ydb.Topic.StreamReadMessage.PartitionSession}
*/
public static final class Builder extends
com.google.protobuf.GeneratedMessageV3.Builder implements
// @@protoc_insertion_point(builder_implements:Ydb.Topic.StreamReadMessage.PartitionSession)
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.PartitionSessionOrBuilder {
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_StreamReadMessage_PartitionSession_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_StreamReadMessage_PartitionSession_fieldAccessorTable
.ensureFieldAccessorsInitialized(
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.PartitionSession.class, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.PartitionSession.Builder.class);
}
// Construct using tech.ydb.proto.topic.YdbTopic.StreamReadMessage.PartitionSession.newBuilder()
private Builder() {
}
private Builder(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
super(parent);
}
@java.lang.Override
public Builder clear() {
super.clear();
bitField0_ = 0;
partitionSessionId_ = 0L;
path_ = "";
partitionId_ = 0L;
return this;
}
@java.lang.Override
public com.google.protobuf.Descriptors.Descriptor
getDescriptorForType() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_StreamReadMessage_PartitionSession_descriptor;
}
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamReadMessage.PartitionSession getDefaultInstanceForType() {
return tech.ydb.proto.topic.YdbTopic.StreamReadMessage.PartitionSession.getDefaultInstance();
}
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamReadMessage.PartitionSession build() {
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.PartitionSession result = buildPartial();
if (!result.isInitialized()) {
throw newUninitializedMessageException(result);
}
return result;
}
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamReadMessage.PartitionSession buildPartial() {
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.PartitionSession result = new tech.ydb.proto.topic.YdbTopic.StreamReadMessage.PartitionSession(this);
if (bitField0_ != 0) { buildPartial0(result); }
onBuilt();
return result;
}
private void buildPartial0(tech.ydb.proto.topic.YdbTopic.StreamReadMessage.PartitionSession result) {
int from_bitField0_ = bitField0_;
if (((from_bitField0_ & 0x00000001) != 0)) {
result.partitionSessionId_ = partitionSessionId_;
}
if (((from_bitField0_ & 0x00000002) != 0)) {
result.path_ = path_;
}
if (((from_bitField0_ & 0x00000004) != 0)) {
result.partitionId_ = partitionId_;
}
}
@java.lang.Override
public Builder clone() {
return super.clone();
}
@java.lang.Override
public Builder setField(
com.google.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) {
return super.setField(field, value);
}
@java.lang.Override
public Builder clearField(
com.google.protobuf.Descriptors.FieldDescriptor field) {
return super.clearField(field);
}
@java.lang.Override
public Builder clearOneof(
com.google.protobuf.Descriptors.OneofDescriptor oneof) {
return super.clearOneof(oneof);
}
@java.lang.Override
public Builder setRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
int index, java.lang.Object value) {
return super.setRepeatedField(field, index, value);
}
@java.lang.Override
public Builder addRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) {
return super.addRepeatedField(field, value);
}
@java.lang.Override
public Builder mergeFrom(com.google.protobuf.Message other) {
if (other instanceof tech.ydb.proto.topic.YdbTopic.StreamReadMessage.PartitionSession) {
return mergeFrom((tech.ydb.proto.topic.YdbTopic.StreamReadMessage.PartitionSession)other);
} else {
super.mergeFrom(other);
return this;
}
}
public Builder mergeFrom(tech.ydb.proto.topic.YdbTopic.StreamReadMessage.PartitionSession other) {
if (other == tech.ydb.proto.topic.YdbTopic.StreamReadMessage.PartitionSession.getDefaultInstance()) return this;
if (other.getPartitionSessionId() != 0L) {
setPartitionSessionId(other.getPartitionSessionId());
}
if (!other.getPath().isEmpty()) {
path_ = other.path_;
bitField0_ |= 0x00000002;
onChanged();
}
if (other.getPartitionId() != 0L) {
setPartitionId(other.getPartitionId());
}
this.mergeUnknownFields(other.getUnknownFields());
onChanged();
return this;
}
@java.lang.Override
public final boolean isInitialized() {
return true;
}
@java.lang.Override
public Builder mergeFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
if (extensionRegistry == null) {
throw new java.lang.NullPointerException();
}
try {
boolean done = false;
while (!done) {
int tag = input.readTag();
switch (tag) {
case 0:
done = true;
break;
case 8: {
partitionSessionId_ = input.readInt64();
bitField0_ |= 0x00000001;
break;
} // case 8
case 18: {
path_ = input.readStringRequireUtf8();
bitField0_ |= 0x00000002;
break;
} // case 18
case 24: {
partitionId_ = input.readInt64();
bitField0_ |= 0x00000004;
break;
} // case 24
default: {
if (!super.parseUnknownField(input, extensionRegistry, tag)) {
done = true; // was an endgroup tag
}
break;
} // default:
} // switch (tag)
} // while (!done)
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.unwrapIOException();
} finally {
onChanged();
} // finally
return this;
}
private int bitField0_;
private long partitionSessionId_ ;
/**
*
* Identifier of partition session. Unique inside one RPC call.
*
*
* int64 partition_session_id = 1;
* @return The partitionSessionId.
*/
@java.lang.Override
public long getPartitionSessionId() {
return partitionSessionId_;
}
/**
*
* Identifier of partition session. Unique inside one RPC call.
*
*
* int64 partition_session_id = 1;
* @param value The partitionSessionId to set.
* @return This builder for chaining.
*/
public Builder setPartitionSessionId(long value) {
partitionSessionId_ = value;
bitField0_ |= 0x00000001;
onChanged();
return this;
}
/**
*
* Identifier of partition session. Unique inside one RPC call.
*
*
* int64 partition_session_id = 1;
* @return This builder for chaining.
*/
public Builder clearPartitionSessionId() {
bitField0_ = (bitField0_ & ~0x00000001);
partitionSessionId_ = 0L;
onChanged();
return this;
}
private java.lang.Object path_ = "";
/**
*
* Topic path of partition.
*
*
* string path = 2;
* @return The path.
*/
public java.lang.String getPath() {
java.lang.Object ref = path_;
if (!(ref instanceof java.lang.String)) {
com.google.protobuf.ByteString bs =
(com.google.protobuf.ByteString) ref;
java.lang.String s = bs.toStringUtf8();
path_ = s;
return s;
} else {
return (java.lang.String) ref;
}
}
/**
*
* Topic path of partition.
*
*
* string path = 2;
* @return The bytes for path.
*/
public com.google.protobuf.ByteString
getPathBytes() {
java.lang.Object ref = path_;
if (ref instanceof String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
path_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
/**
*
* Topic path of partition.
*
*
* string path = 2;
* @param value The path to set.
* @return This builder for chaining.
*/
public Builder setPath(
java.lang.String value) {
if (value == null) { throw new NullPointerException(); }
path_ = value;
bitField0_ |= 0x00000002;
onChanged();
return this;
}
/**
*
* Topic path of partition.
*
*
* string path = 2;
* @return This builder for chaining.
*/
public Builder clearPath() {
path_ = getDefaultInstance().getPath();
bitField0_ = (bitField0_ & ~0x00000002);
onChanged();
return this;
}
/**
*
* Topic path of partition.
*
*
* string path = 2;
* @param value The bytes for path to set.
* @return This builder for chaining.
*/
public Builder setPathBytes(
com.google.protobuf.ByteString value) {
if (value == null) { throw new NullPointerException(); }
checkByteStringIsUtf8(value);
path_ = value;
bitField0_ |= 0x00000002;
onChanged();
return this;
}
private long partitionId_ ;
/**
*
* Partition identifier.
*
*
* int64 partition_id = 3;
* @return The partitionId.
*/
@java.lang.Override
public long getPartitionId() {
return partitionId_;
}
/**
*
* Partition identifier.
*
*
* int64 partition_id = 3;
* @param value The partitionId to set.
* @return This builder for chaining.
*/
public Builder setPartitionId(long value) {
partitionId_ = value;
bitField0_ |= 0x00000004;
onChanged();
return this;
}
/**
*
* Partition identifier.
*
*
* int64 partition_id = 3;
* @return This builder for chaining.
*/
public Builder clearPartitionId() {
bitField0_ = (bitField0_ & ~0x00000004);
partitionId_ = 0L;
onChanged();
return this;
}
@java.lang.Override
public final Builder setUnknownFields(
final com.google.protobuf.UnknownFieldSet unknownFields) {
return super.setUnknownFields(unknownFields);
}
@java.lang.Override
public final Builder mergeUnknownFields(
final com.google.protobuf.UnknownFieldSet unknownFields) {
return super.mergeUnknownFields(unknownFields);
}
// @@protoc_insertion_point(builder_scope:Ydb.Topic.StreamReadMessage.PartitionSession)
}
// @@protoc_insertion_point(class_scope:Ydb.Topic.StreamReadMessage.PartitionSession)
private static final tech.ydb.proto.topic.YdbTopic.StreamReadMessage.PartitionSession DEFAULT_INSTANCE;
static {
DEFAULT_INSTANCE = new tech.ydb.proto.topic.YdbTopic.StreamReadMessage.PartitionSession();
}
public static tech.ydb.proto.topic.YdbTopic.StreamReadMessage.PartitionSession getDefaultInstance() {
return DEFAULT_INSTANCE;
}
private static final com.google.protobuf.Parser
PARSER = new com.google.protobuf.AbstractParser() {
@java.lang.Override
public PartitionSession parsePartialFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
Builder builder = newBuilder();
try {
builder.mergeFrom(input, extensionRegistry);
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.setUnfinishedMessage(builder.buildPartial());
} catch (com.google.protobuf.UninitializedMessageException e) {
throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial());
} catch (java.io.IOException e) {
throw new com.google.protobuf.InvalidProtocolBufferException(e)
.setUnfinishedMessage(builder.buildPartial());
}
return builder.buildPartial();
}
};
public static com.google.protobuf.Parser parser() {
return PARSER;
}
@java.lang.Override
public com.google.protobuf.Parser getParserForType() {
return PARSER;
}
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamReadMessage.PartitionSession getDefaultInstanceForType() {
return DEFAULT_INSTANCE;
}
}
public interface FromClientOrBuilder extends
// @@protoc_insertion_point(interface_extends:Ydb.Topic.StreamReadMessage.FromClient)
com.google.protobuf.MessageOrBuilder {
/**
*
* Client requests.
*
*
* .Ydb.Topic.StreamReadMessage.InitRequest init_request = 1;
* @return Whether the initRequest field is set.
*/
boolean hasInitRequest();
/**
*
* Client requests.
*
*
* .Ydb.Topic.StreamReadMessage.InitRequest init_request = 1;
* @return The initRequest.
*/
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest getInitRequest();
/**
*
* Client requests.
*
*
* .Ydb.Topic.StreamReadMessage.InitRequest init_request = 1;
*/
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequestOrBuilder getInitRequestOrBuilder();
/**
* .Ydb.Topic.StreamReadMessage.ReadRequest read_request = 2;
* @return Whether the readRequest field is set.
*/
boolean hasReadRequest();
/**
* .Ydb.Topic.StreamReadMessage.ReadRequest read_request = 2;
* @return The readRequest.
*/
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadRequest getReadRequest();
/**
* .Ydb.Topic.StreamReadMessage.ReadRequest read_request = 2;
*/
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadRequestOrBuilder getReadRequestOrBuilder();
/**
* .Ydb.Topic.StreamReadMessage.CommitOffsetRequest commit_offset_request = 3;
* @return Whether the commitOffsetRequest field is set.
*/
boolean hasCommitOffsetRequest();
/**
* .Ydb.Topic.StreamReadMessage.CommitOffsetRequest commit_offset_request = 3;
* @return The commitOffsetRequest.
*/
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.CommitOffsetRequest getCommitOffsetRequest();
/**
* .Ydb.Topic.StreamReadMessage.CommitOffsetRequest commit_offset_request = 3;
*/
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.CommitOffsetRequestOrBuilder getCommitOffsetRequestOrBuilder();
/**
* .Ydb.Topic.StreamReadMessage.PartitionSessionStatusRequest partition_session_status_request = 4;
* @return Whether the partitionSessionStatusRequest field is set.
*/
boolean hasPartitionSessionStatusRequest();
/**
* .Ydb.Topic.StreamReadMessage.PartitionSessionStatusRequest partition_session_status_request = 4;
* @return The partitionSessionStatusRequest.
*/
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.PartitionSessionStatusRequest getPartitionSessionStatusRequest();
/**
* .Ydb.Topic.StreamReadMessage.PartitionSessionStatusRequest partition_session_status_request = 4;
*/
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.PartitionSessionStatusRequestOrBuilder getPartitionSessionStatusRequestOrBuilder();
/**
* .Ydb.Topic.UpdateTokenRequest update_token_request = 5;
* @return Whether the updateTokenRequest field is set.
*/
boolean hasUpdateTokenRequest();
/**
* .Ydb.Topic.UpdateTokenRequest update_token_request = 5;
* @return The updateTokenRequest.
*/
tech.ydb.proto.topic.YdbTopic.UpdateTokenRequest getUpdateTokenRequest();
/**
* .Ydb.Topic.UpdateTokenRequest update_token_request = 5;
*/
tech.ydb.proto.topic.YdbTopic.UpdateTokenRequestOrBuilder getUpdateTokenRequestOrBuilder();
/**
* .Ydb.Topic.StreamReadMessage.DirectReadAck direct_read_ack = 8;
* @return Whether the directReadAck field is set.
*/
boolean hasDirectReadAck();
/**
* .Ydb.Topic.StreamReadMessage.DirectReadAck direct_read_ack = 8;
* @return The directReadAck.
*/
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.DirectReadAck getDirectReadAck();
/**
* .Ydb.Topic.StreamReadMessage.DirectReadAck direct_read_ack = 8;
*/
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.DirectReadAckOrBuilder getDirectReadAckOrBuilder();
/**
*
* Responses to respective server commands.
*
*
* .Ydb.Topic.StreamReadMessage.StartPartitionSessionResponse start_partition_session_response = 6;
* @return Whether the startPartitionSessionResponse field is set.
*/
boolean hasStartPartitionSessionResponse();
/**
*
* Responses to respective server commands.
*
*
* .Ydb.Topic.StreamReadMessage.StartPartitionSessionResponse start_partition_session_response = 6;
* @return The startPartitionSessionResponse.
*/
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StartPartitionSessionResponse getStartPartitionSessionResponse();
/**
*
* Responses to respective server commands.
*
*
* .Ydb.Topic.StreamReadMessage.StartPartitionSessionResponse start_partition_session_response = 6;
*/
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StartPartitionSessionResponseOrBuilder getStartPartitionSessionResponseOrBuilder();
/**
* .Ydb.Topic.StreamReadMessage.StopPartitionSessionResponse stop_partition_session_response = 7;
* @return Whether the stopPartitionSessionResponse field is set.
*/
boolean hasStopPartitionSessionResponse();
/**
* .Ydb.Topic.StreamReadMessage.StopPartitionSessionResponse stop_partition_session_response = 7;
* @return The stopPartitionSessionResponse.
*/
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StopPartitionSessionResponse getStopPartitionSessionResponse();
/**
* .Ydb.Topic.StreamReadMessage.StopPartitionSessionResponse stop_partition_session_response = 7;
*/
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StopPartitionSessionResponseOrBuilder getStopPartitionSessionResponseOrBuilder();
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.FromClient.ClientMessageCase getClientMessageCase();
}
/**
*
* Client-server message for read session. Contains one of:
* InitRequest - handshake request.
* ReadRequest - request for data.
* CommitOffsetRequest - request for commit of some read data.
* PartitionSessionStatusRequest - request for session status
* UpdateTokenRequest - request to update auth token
* DirectReadAck - client signals it has finished direct reading from the partition node.
*
* StartPartitionSessionResponse - Response to StreamReadServerMessage.StartPartitionSessionRequest.
* Client signals it is ready to get data from partition.
* StopPartitionSessionResponse - Response to StreamReadServerMessage.StopPartitionSessionRequest.
* Client signals it has finished working with partition. Mandatory for graceful stop, optional otherwise.
*
*
* Protobuf type {@code Ydb.Topic.StreamReadMessage.FromClient}
*/
public static final class FromClient extends
com.google.protobuf.GeneratedMessageV3 implements
// @@protoc_insertion_point(message_implements:Ydb.Topic.StreamReadMessage.FromClient)
FromClientOrBuilder {
private static final long serialVersionUID = 0L;
// Use FromClient.newBuilder() to construct.
private FromClient(com.google.protobuf.GeneratedMessageV3.Builder> builder) {
super(builder);
}
private FromClient() {
}
@java.lang.Override
@SuppressWarnings({"unused"})
protected java.lang.Object newInstance(
UnusedPrivateParameter unused) {
return new FromClient();
}
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_StreamReadMessage_FromClient_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_StreamReadMessage_FromClient_fieldAccessorTable
.ensureFieldAccessorsInitialized(
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.FromClient.class, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.FromClient.Builder.class);
}
private int clientMessageCase_ = 0;
@SuppressWarnings("serial")
private java.lang.Object clientMessage_;
public enum ClientMessageCase
implements com.google.protobuf.Internal.EnumLite,
com.google.protobuf.AbstractMessage.InternalOneOfEnum {
INIT_REQUEST(1),
READ_REQUEST(2),
COMMIT_OFFSET_REQUEST(3),
PARTITION_SESSION_STATUS_REQUEST(4),
UPDATE_TOKEN_REQUEST(5),
DIRECT_READ_ACK(8),
START_PARTITION_SESSION_RESPONSE(6),
STOP_PARTITION_SESSION_RESPONSE(7),
CLIENTMESSAGE_NOT_SET(0);
private final int value;
private ClientMessageCase(int value) {
this.value = value;
}
/**
* @param value The number of the enum to look for.
* @return The enum associated with the given number.
* @deprecated Use {@link #forNumber(int)} instead.
*/
@java.lang.Deprecated
public static ClientMessageCase valueOf(int value) {
return forNumber(value);
}
public static ClientMessageCase forNumber(int value) {
switch (value) {
case 1: return INIT_REQUEST;
case 2: return READ_REQUEST;
case 3: return COMMIT_OFFSET_REQUEST;
case 4: return PARTITION_SESSION_STATUS_REQUEST;
case 5: return UPDATE_TOKEN_REQUEST;
case 8: return DIRECT_READ_ACK;
case 6: return START_PARTITION_SESSION_RESPONSE;
case 7: return STOP_PARTITION_SESSION_RESPONSE;
case 0: return CLIENTMESSAGE_NOT_SET;
default: return null;
}
}
public int getNumber() {
return this.value;
}
};
public ClientMessageCase
getClientMessageCase() {
return ClientMessageCase.forNumber(
clientMessageCase_);
}
public static final int INIT_REQUEST_FIELD_NUMBER = 1;
/**
*
* Client requests.
*
*
* .Ydb.Topic.StreamReadMessage.InitRequest init_request = 1;
* @return Whether the initRequest field is set.
*/
@java.lang.Override
public boolean hasInitRequest() {
return clientMessageCase_ == 1;
}
/**
*
* Client requests.
*
*
* .Ydb.Topic.StreamReadMessage.InitRequest init_request = 1;
* @return The initRequest.
*/
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest getInitRequest() {
if (clientMessageCase_ == 1) {
return (tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest) clientMessage_;
}
return tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest.getDefaultInstance();
}
/**
*
* Client requests.
*
*
* .Ydb.Topic.StreamReadMessage.InitRequest init_request = 1;
*/
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequestOrBuilder getInitRequestOrBuilder() {
if (clientMessageCase_ == 1) {
return (tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest) clientMessage_;
}
return tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest.getDefaultInstance();
}
public static final int READ_REQUEST_FIELD_NUMBER = 2;
/**
* .Ydb.Topic.StreamReadMessage.ReadRequest read_request = 2;
* @return Whether the readRequest field is set.
*/
@java.lang.Override
public boolean hasReadRequest() {
return clientMessageCase_ == 2;
}
/**
* .Ydb.Topic.StreamReadMessage.ReadRequest read_request = 2;
* @return The readRequest.
*/
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadRequest getReadRequest() {
if (clientMessageCase_ == 2) {
return (tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadRequest) clientMessage_;
}
return tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadRequest.getDefaultInstance();
}
/**
* .Ydb.Topic.StreamReadMessage.ReadRequest read_request = 2;
*/
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadRequestOrBuilder getReadRequestOrBuilder() {
if (clientMessageCase_ == 2) {
return (tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadRequest) clientMessage_;
}
return tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadRequest.getDefaultInstance();
}
public static final int COMMIT_OFFSET_REQUEST_FIELD_NUMBER = 3;
/**
* .Ydb.Topic.StreamReadMessage.CommitOffsetRequest commit_offset_request = 3;
* @return Whether the commitOffsetRequest field is set.
*/
@java.lang.Override
public boolean hasCommitOffsetRequest() {
return clientMessageCase_ == 3;
}
/**
* .Ydb.Topic.StreamReadMessage.CommitOffsetRequest commit_offset_request = 3;
* @return The commitOffsetRequest.
*/
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamReadMessage.CommitOffsetRequest getCommitOffsetRequest() {
if (clientMessageCase_ == 3) {
return (tech.ydb.proto.topic.YdbTopic.StreamReadMessage.CommitOffsetRequest) clientMessage_;
}
return tech.ydb.proto.topic.YdbTopic.StreamReadMessage.CommitOffsetRequest.getDefaultInstance();
}
/**
* .Ydb.Topic.StreamReadMessage.CommitOffsetRequest commit_offset_request = 3;
*/
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamReadMessage.CommitOffsetRequestOrBuilder getCommitOffsetRequestOrBuilder() {
if (clientMessageCase_ == 3) {
return (tech.ydb.proto.topic.YdbTopic.StreamReadMessage.CommitOffsetRequest) clientMessage_;
}
return tech.ydb.proto.topic.YdbTopic.StreamReadMessage.CommitOffsetRequest.getDefaultInstance();
}
public static final int PARTITION_SESSION_STATUS_REQUEST_FIELD_NUMBER = 4;
/**
* .Ydb.Topic.StreamReadMessage.PartitionSessionStatusRequest partition_session_status_request = 4;
* @return Whether the partitionSessionStatusRequest field is set.
*/
@java.lang.Override
public boolean hasPartitionSessionStatusRequest() {
return clientMessageCase_ == 4;
}
/**
* .Ydb.Topic.StreamReadMessage.PartitionSessionStatusRequest partition_session_status_request = 4;
* @return The partitionSessionStatusRequest.
*/
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamReadMessage.PartitionSessionStatusRequest getPartitionSessionStatusRequest() {
if (clientMessageCase_ == 4) {
return (tech.ydb.proto.topic.YdbTopic.StreamReadMessage.PartitionSessionStatusRequest) clientMessage_;
}
return tech.ydb.proto.topic.YdbTopic.StreamReadMessage.PartitionSessionStatusRequest.getDefaultInstance();
}
/**
* .Ydb.Topic.StreamReadMessage.PartitionSessionStatusRequest partition_session_status_request = 4;
*/
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamReadMessage.PartitionSessionStatusRequestOrBuilder getPartitionSessionStatusRequestOrBuilder() {
if (clientMessageCase_ == 4) {
return (tech.ydb.proto.topic.YdbTopic.StreamReadMessage.PartitionSessionStatusRequest) clientMessage_;
}
return tech.ydb.proto.topic.YdbTopic.StreamReadMessage.PartitionSessionStatusRequest.getDefaultInstance();
}
public static final int UPDATE_TOKEN_REQUEST_FIELD_NUMBER = 5;
/**
* .Ydb.Topic.UpdateTokenRequest update_token_request = 5;
* @return Whether the updateTokenRequest field is set.
*/
@java.lang.Override
public boolean hasUpdateTokenRequest() {
return clientMessageCase_ == 5;
}
/**
* .Ydb.Topic.UpdateTokenRequest update_token_request = 5;
* @return The updateTokenRequest.
*/
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.UpdateTokenRequest getUpdateTokenRequest() {
if (clientMessageCase_ == 5) {
return (tech.ydb.proto.topic.YdbTopic.UpdateTokenRequest) clientMessage_;
}
return tech.ydb.proto.topic.YdbTopic.UpdateTokenRequest.getDefaultInstance();
}
/**
* .Ydb.Topic.UpdateTokenRequest update_token_request = 5;
*/
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.UpdateTokenRequestOrBuilder getUpdateTokenRequestOrBuilder() {
if (clientMessageCase_ == 5) {
return (tech.ydb.proto.topic.YdbTopic.UpdateTokenRequest) clientMessage_;
}
return tech.ydb.proto.topic.YdbTopic.UpdateTokenRequest.getDefaultInstance();
}
public static final int DIRECT_READ_ACK_FIELD_NUMBER = 8;
/**
* .Ydb.Topic.StreamReadMessage.DirectReadAck direct_read_ack = 8;
* @return Whether the directReadAck field is set.
*/
@java.lang.Override
public boolean hasDirectReadAck() {
return clientMessageCase_ == 8;
}
/**
* .Ydb.Topic.StreamReadMessage.DirectReadAck direct_read_ack = 8;
* @return The directReadAck.
*/
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamReadMessage.DirectReadAck getDirectReadAck() {
if (clientMessageCase_ == 8) {
return (tech.ydb.proto.topic.YdbTopic.StreamReadMessage.DirectReadAck) clientMessage_;
}
return tech.ydb.proto.topic.YdbTopic.StreamReadMessage.DirectReadAck.getDefaultInstance();
}
/**
* .Ydb.Topic.StreamReadMessage.DirectReadAck direct_read_ack = 8;
*/
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamReadMessage.DirectReadAckOrBuilder getDirectReadAckOrBuilder() {
if (clientMessageCase_ == 8) {
return (tech.ydb.proto.topic.YdbTopic.StreamReadMessage.DirectReadAck) clientMessage_;
}
return tech.ydb.proto.topic.YdbTopic.StreamReadMessage.DirectReadAck.getDefaultInstance();
}
public static final int START_PARTITION_SESSION_RESPONSE_FIELD_NUMBER = 6;
/**
*
* Responses to respective server commands.
*
*
* .Ydb.Topic.StreamReadMessage.StartPartitionSessionResponse start_partition_session_response = 6;
* @return Whether the startPartitionSessionResponse field is set.
*/
@java.lang.Override
public boolean hasStartPartitionSessionResponse() {
return clientMessageCase_ == 6;
}
/**
*
* Responses to respective server commands.
*
*
* .Ydb.Topic.StreamReadMessage.StartPartitionSessionResponse start_partition_session_response = 6;
* @return The startPartitionSessionResponse.
*/
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StartPartitionSessionResponse getStartPartitionSessionResponse() {
if (clientMessageCase_ == 6) {
return (tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StartPartitionSessionResponse) clientMessage_;
}
return tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StartPartitionSessionResponse.getDefaultInstance();
}
/**
*
* Responses to respective server commands.
*
*
* .Ydb.Topic.StreamReadMessage.StartPartitionSessionResponse start_partition_session_response = 6;
*/
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StartPartitionSessionResponseOrBuilder getStartPartitionSessionResponseOrBuilder() {
if (clientMessageCase_ == 6) {
return (tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StartPartitionSessionResponse) clientMessage_;
}
return tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StartPartitionSessionResponse.getDefaultInstance();
}
public static final int STOP_PARTITION_SESSION_RESPONSE_FIELD_NUMBER = 7;
/**
* .Ydb.Topic.StreamReadMessage.StopPartitionSessionResponse stop_partition_session_response = 7;
* @return Whether the stopPartitionSessionResponse field is set.
*/
@java.lang.Override
public boolean hasStopPartitionSessionResponse() {
return clientMessageCase_ == 7;
}
/**
* .Ydb.Topic.StreamReadMessage.StopPartitionSessionResponse stop_partition_session_response = 7;
* @return The stopPartitionSessionResponse.
*/
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StopPartitionSessionResponse getStopPartitionSessionResponse() {
if (clientMessageCase_ == 7) {
return (tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StopPartitionSessionResponse) clientMessage_;
}
return tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StopPartitionSessionResponse.getDefaultInstance();
}
/**
* .Ydb.Topic.StreamReadMessage.StopPartitionSessionResponse stop_partition_session_response = 7;
*/
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StopPartitionSessionResponseOrBuilder getStopPartitionSessionResponseOrBuilder() {
if (clientMessageCase_ == 7) {
return (tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StopPartitionSessionResponse) clientMessage_;
}
return tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StopPartitionSessionResponse.getDefaultInstance();
}
private byte memoizedIsInitialized = -1;
@java.lang.Override
public final boolean isInitialized() {
byte isInitialized = memoizedIsInitialized;
if (isInitialized == 1) return true;
if (isInitialized == 0) return false;
memoizedIsInitialized = 1;
return true;
}
@java.lang.Override
public void writeTo(com.google.protobuf.CodedOutputStream output)
throws java.io.IOException {
if (clientMessageCase_ == 1) {
output.writeMessage(1, (tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest) clientMessage_);
}
if (clientMessageCase_ == 2) {
output.writeMessage(2, (tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadRequest) clientMessage_);
}
if (clientMessageCase_ == 3) {
output.writeMessage(3, (tech.ydb.proto.topic.YdbTopic.StreamReadMessage.CommitOffsetRequest) clientMessage_);
}
if (clientMessageCase_ == 4) {
output.writeMessage(4, (tech.ydb.proto.topic.YdbTopic.StreamReadMessage.PartitionSessionStatusRequest) clientMessage_);
}
if (clientMessageCase_ == 5) {
output.writeMessage(5, (tech.ydb.proto.topic.YdbTopic.UpdateTokenRequest) clientMessage_);
}
if (clientMessageCase_ == 6) {
output.writeMessage(6, (tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StartPartitionSessionResponse) clientMessage_);
}
if (clientMessageCase_ == 7) {
output.writeMessage(7, (tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StopPartitionSessionResponse) clientMessage_);
}
if (clientMessageCase_ == 8) {
output.writeMessage(8, (tech.ydb.proto.topic.YdbTopic.StreamReadMessage.DirectReadAck) clientMessage_);
}
getUnknownFields().writeTo(output);
}
@java.lang.Override
public int getSerializedSize() {
int size = memoizedSize;
if (size != -1) return size;
size = 0;
if (clientMessageCase_ == 1) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(1, (tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest) clientMessage_);
}
if (clientMessageCase_ == 2) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(2, (tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadRequest) clientMessage_);
}
if (clientMessageCase_ == 3) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(3, (tech.ydb.proto.topic.YdbTopic.StreamReadMessage.CommitOffsetRequest) clientMessage_);
}
if (clientMessageCase_ == 4) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(4, (tech.ydb.proto.topic.YdbTopic.StreamReadMessage.PartitionSessionStatusRequest) clientMessage_);
}
if (clientMessageCase_ == 5) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(5, (tech.ydb.proto.topic.YdbTopic.UpdateTokenRequest) clientMessage_);
}
if (clientMessageCase_ == 6) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(6, (tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StartPartitionSessionResponse) clientMessage_);
}
if (clientMessageCase_ == 7) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(7, (tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StopPartitionSessionResponse) clientMessage_);
}
if (clientMessageCase_ == 8) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(8, (tech.ydb.proto.topic.YdbTopic.StreamReadMessage.DirectReadAck) clientMessage_);
}
size += getUnknownFields().getSerializedSize();
memoizedSize = size;
return size;
}
@java.lang.Override
public boolean equals(final java.lang.Object obj) {
if (obj == this) {
return true;
}
if (!(obj instanceof tech.ydb.proto.topic.YdbTopic.StreamReadMessage.FromClient)) {
return super.equals(obj);
}
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.FromClient other = (tech.ydb.proto.topic.YdbTopic.StreamReadMessage.FromClient) obj;
if (!getClientMessageCase().equals(other.getClientMessageCase())) return false;
switch (clientMessageCase_) {
case 1:
if (!getInitRequest()
.equals(other.getInitRequest())) return false;
break;
case 2:
if (!getReadRequest()
.equals(other.getReadRequest())) return false;
break;
case 3:
if (!getCommitOffsetRequest()
.equals(other.getCommitOffsetRequest())) return false;
break;
case 4:
if (!getPartitionSessionStatusRequest()
.equals(other.getPartitionSessionStatusRequest())) return false;
break;
case 5:
if (!getUpdateTokenRequest()
.equals(other.getUpdateTokenRequest())) return false;
break;
case 8:
if (!getDirectReadAck()
.equals(other.getDirectReadAck())) return false;
break;
case 6:
if (!getStartPartitionSessionResponse()
.equals(other.getStartPartitionSessionResponse())) return false;
break;
case 7:
if (!getStopPartitionSessionResponse()
.equals(other.getStopPartitionSessionResponse())) return false;
break;
case 0:
default:
}
if (!getUnknownFields().equals(other.getUnknownFields())) return false;
return true;
}
@java.lang.Override
public int hashCode() {
if (memoizedHashCode != 0) {
return memoizedHashCode;
}
int hash = 41;
hash = (19 * hash) + getDescriptor().hashCode();
switch (clientMessageCase_) {
case 1:
hash = (37 * hash) + INIT_REQUEST_FIELD_NUMBER;
hash = (53 * hash) + getInitRequest().hashCode();
break;
case 2:
hash = (37 * hash) + READ_REQUEST_FIELD_NUMBER;
hash = (53 * hash) + getReadRequest().hashCode();
break;
case 3:
hash = (37 * hash) + COMMIT_OFFSET_REQUEST_FIELD_NUMBER;
hash = (53 * hash) + getCommitOffsetRequest().hashCode();
break;
case 4:
hash = (37 * hash) + PARTITION_SESSION_STATUS_REQUEST_FIELD_NUMBER;
hash = (53 * hash) + getPartitionSessionStatusRequest().hashCode();
break;
case 5:
hash = (37 * hash) + UPDATE_TOKEN_REQUEST_FIELD_NUMBER;
hash = (53 * hash) + getUpdateTokenRequest().hashCode();
break;
case 8:
hash = (37 * hash) + DIRECT_READ_ACK_FIELD_NUMBER;
hash = (53 * hash) + getDirectReadAck().hashCode();
break;
case 6:
hash = (37 * hash) + START_PARTITION_SESSION_RESPONSE_FIELD_NUMBER;
hash = (53 * hash) + getStartPartitionSessionResponse().hashCode();
break;
case 7:
hash = (37 * hash) + STOP_PARTITION_SESSION_RESPONSE_FIELD_NUMBER;
hash = (53 * hash) + getStopPartitionSessionResponse().hashCode();
break;
case 0:
default:
}
hash = (29 * hash) + getUnknownFields().hashCode();
memoizedHashCode = hash;
return hash;
}
public static tech.ydb.proto.topic.YdbTopic.StreamReadMessage.FromClient parseFrom(
java.nio.ByteBuffer data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static tech.ydb.proto.topic.YdbTopic.StreamReadMessage.FromClient parseFrom(
java.nio.ByteBuffer data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.StreamReadMessage.FromClient parseFrom(
com.google.protobuf.ByteString data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static tech.ydb.proto.topic.YdbTopic.StreamReadMessage.FromClient parseFrom(
com.google.protobuf.ByteString data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.StreamReadMessage.FromClient parseFrom(byte[] data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static tech.ydb.proto.topic.YdbTopic.StreamReadMessage.FromClient parseFrom(
byte[] data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.StreamReadMessage.FromClient parseFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static tech.ydb.proto.topic.YdbTopic.StreamReadMessage.FromClient parseFrom(
java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.StreamReadMessage.FromClient parseDelimitedFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input);
}
public static tech.ydb.proto.topic.YdbTopic.StreamReadMessage.FromClient parseDelimitedFrom(
java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.StreamReadMessage.FromClient parseFrom(
com.google.protobuf.CodedInputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static tech.ydb.proto.topic.YdbTopic.StreamReadMessage.FromClient parseFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry);
}
@java.lang.Override
public Builder newBuilderForType() { return newBuilder(); }
public static Builder newBuilder() {
return DEFAULT_INSTANCE.toBuilder();
}
public static Builder newBuilder(tech.ydb.proto.topic.YdbTopic.StreamReadMessage.FromClient prototype) {
return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
}
@java.lang.Override
public Builder toBuilder() {
return this == DEFAULT_INSTANCE
? new Builder() : new Builder().mergeFrom(this);
}
@java.lang.Override
protected Builder newBuilderForType(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
Builder builder = new Builder(parent);
return builder;
}
/**
*
* Client-server message for read session. Contains one of:
* InitRequest - handshake request.
* ReadRequest - request for data.
* CommitOffsetRequest - request for commit of some read data.
* PartitionSessionStatusRequest - request for session status
* UpdateTokenRequest - request to update auth token
* DirectReadAck - client signals it has finished direct reading from the partition node.
*
* StartPartitionSessionResponse - Response to StreamReadServerMessage.StartPartitionSessionRequest.
* Client signals it is ready to get data from partition.
* StopPartitionSessionResponse - Response to StreamReadServerMessage.StopPartitionSessionRequest.
* Client signals it has finished working with partition. Mandatory for graceful stop, optional otherwise.
*
*
* Protobuf type {@code Ydb.Topic.StreamReadMessage.FromClient}
*/
public static final class Builder extends
com.google.protobuf.GeneratedMessageV3.Builder implements
// @@protoc_insertion_point(builder_implements:Ydb.Topic.StreamReadMessage.FromClient)
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.FromClientOrBuilder {
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_StreamReadMessage_FromClient_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_StreamReadMessage_FromClient_fieldAccessorTable
.ensureFieldAccessorsInitialized(
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.FromClient.class, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.FromClient.Builder.class);
}
// Construct using tech.ydb.proto.topic.YdbTopic.StreamReadMessage.FromClient.newBuilder()
private Builder() {
}
private Builder(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
super(parent);
}
@java.lang.Override
public Builder clear() {
super.clear();
bitField0_ = 0;
if (initRequestBuilder_ != null) {
initRequestBuilder_.clear();
}
if (readRequestBuilder_ != null) {
readRequestBuilder_.clear();
}
if (commitOffsetRequestBuilder_ != null) {
commitOffsetRequestBuilder_.clear();
}
if (partitionSessionStatusRequestBuilder_ != null) {
partitionSessionStatusRequestBuilder_.clear();
}
if (updateTokenRequestBuilder_ != null) {
updateTokenRequestBuilder_.clear();
}
if (directReadAckBuilder_ != null) {
directReadAckBuilder_.clear();
}
if (startPartitionSessionResponseBuilder_ != null) {
startPartitionSessionResponseBuilder_.clear();
}
if (stopPartitionSessionResponseBuilder_ != null) {
stopPartitionSessionResponseBuilder_.clear();
}
clientMessageCase_ = 0;
clientMessage_ = null;
return this;
}
@java.lang.Override
public com.google.protobuf.Descriptors.Descriptor
getDescriptorForType() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_StreamReadMessage_FromClient_descriptor;
}
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamReadMessage.FromClient getDefaultInstanceForType() {
return tech.ydb.proto.topic.YdbTopic.StreamReadMessage.FromClient.getDefaultInstance();
}
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamReadMessage.FromClient build() {
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.FromClient result = buildPartial();
if (!result.isInitialized()) {
throw newUninitializedMessageException(result);
}
return result;
}
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamReadMessage.FromClient buildPartial() {
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.FromClient result = new tech.ydb.proto.topic.YdbTopic.StreamReadMessage.FromClient(this);
if (bitField0_ != 0) { buildPartial0(result); }
buildPartialOneofs(result);
onBuilt();
return result;
}
private void buildPartial0(tech.ydb.proto.topic.YdbTopic.StreamReadMessage.FromClient result) {
int from_bitField0_ = bitField0_;
}
private void buildPartialOneofs(tech.ydb.proto.topic.YdbTopic.StreamReadMessage.FromClient result) {
result.clientMessageCase_ = clientMessageCase_;
result.clientMessage_ = this.clientMessage_;
if (clientMessageCase_ == 1 &&
initRequestBuilder_ != null) {
result.clientMessage_ = initRequestBuilder_.build();
}
if (clientMessageCase_ == 2 &&
readRequestBuilder_ != null) {
result.clientMessage_ = readRequestBuilder_.build();
}
if (clientMessageCase_ == 3 &&
commitOffsetRequestBuilder_ != null) {
result.clientMessage_ = commitOffsetRequestBuilder_.build();
}
if (clientMessageCase_ == 4 &&
partitionSessionStatusRequestBuilder_ != null) {
result.clientMessage_ = partitionSessionStatusRequestBuilder_.build();
}
if (clientMessageCase_ == 5 &&
updateTokenRequestBuilder_ != null) {
result.clientMessage_ = updateTokenRequestBuilder_.build();
}
if (clientMessageCase_ == 8 &&
directReadAckBuilder_ != null) {
result.clientMessage_ = directReadAckBuilder_.build();
}
if (clientMessageCase_ == 6 &&
startPartitionSessionResponseBuilder_ != null) {
result.clientMessage_ = startPartitionSessionResponseBuilder_.build();
}
if (clientMessageCase_ == 7 &&
stopPartitionSessionResponseBuilder_ != null) {
result.clientMessage_ = stopPartitionSessionResponseBuilder_.build();
}
}
@java.lang.Override
public Builder clone() {
return super.clone();
}
@java.lang.Override
public Builder setField(
com.google.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) {
return super.setField(field, value);
}
@java.lang.Override
public Builder clearField(
com.google.protobuf.Descriptors.FieldDescriptor field) {
return super.clearField(field);
}
@java.lang.Override
public Builder clearOneof(
com.google.protobuf.Descriptors.OneofDescriptor oneof) {
return super.clearOneof(oneof);
}
@java.lang.Override
public Builder setRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
int index, java.lang.Object value) {
return super.setRepeatedField(field, index, value);
}
@java.lang.Override
public Builder addRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) {
return super.addRepeatedField(field, value);
}
@java.lang.Override
public Builder mergeFrom(com.google.protobuf.Message other) {
if (other instanceof tech.ydb.proto.topic.YdbTopic.StreamReadMessage.FromClient) {
return mergeFrom((tech.ydb.proto.topic.YdbTopic.StreamReadMessage.FromClient)other);
} else {
super.mergeFrom(other);
return this;
}
}
public Builder mergeFrom(tech.ydb.proto.topic.YdbTopic.StreamReadMessage.FromClient other) {
if (other == tech.ydb.proto.topic.YdbTopic.StreamReadMessage.FromClient.getDefaultInstance()) return this;
switch (other.getClientMessageCase()) {
case INIT_REQUEST: {
mergeInitRequest(other.getInitRequest());
break;
}
case READ_REQUEST: {
mergeReadRequest(other.getReadRequest());
break;
}
case COMMIT_OFFSET_REQUEST: {
mergeCommitOffsetRequest(other.getCommitOffsetRequest());
break;
}
case PARTITION_SESSION_STATUS_REQUEST: {
mergePartitionSessionStatusRequest(other.getPartitionSessionStatusRequest());
break;
}
case UPDATE_TOKEN_REQUEST: {
mergeUpdateTokenRequest(other.getUpdateTokenRequest());
break;
}
case DIRECT_READ_ACK: {
mergeDirectReadAck(other.getDirectReadAck());
break;
}
case START_PARTITION_SESSION_RESPONSE: {
mergeStartPartitionSessionResponse(other.getStartPartitionSessionResponse());
break;
}
case STOP_PARTITION_SESSION_RESPONSE: {
mergeStopPartitionSessionResponse(other.getStopPartitionSessionResponse());
break;
}
case CLIENTMESSAGE_NOT_SET: {
break;
}
}
this.mergeUnknownFields(other.getUnknownFields());
onChanged();
return this;
}
@java.lang.Override
public final boolean isInitialized() {
return true;
}
@java.lang.Override
public Builder mergeFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
if (extensionRegistry == null) {
throw new java.lang.NullPointerException();
}
try {
boolean done = false;
while (!done) {
int tag = input.readTag();
switch (tag) {
case 0:
done = true;
break;
case 10: {
input.readMessage(
getInitRequestFieldBuilder().getBuilder(),
extensionRegistry);
clientMessageCase_ = 1;
break;
} // case 10
case 18: {
input.readMessage(
getReadRequestFieldBuilder().getBuilder(),
extensionRegistry);
clientMessageCase_ = 2;
break;
} // case 18
case 26: {
input.readMessage(
getCommitOffsetRequestFieldBuilder().getBuilder(),
extensionRegistry);
clientMessageCase_ = 3;
break;
} // case 26
case 34: {
input.readMessage(
getPartitionSessionStatusRequestFieldBuilder().getBuilder(),
extensionRegistry);
clientMessageCase_ = 4;
break;
} // case 34
case 42: {
input.readMessage(
getUpdateTokenRequestFieldBuilder().getBuilder(),
extensionRegistry);
clientMessageCase_ = 5;
break;
} // case 42
case 50: {
input.readMessage(
getStartPartitionSessionResponseFieldBuilder().getBuilder(),
extensionRegistry);
clientMessageCase_ = 6;
break;
} // case 50
case 58: {
input.readMessage(
getStopPartitionSessionResponseFieldBuilder().getBuilder(),
extensionRegistry);
clientMessageCase_ = 7;
break;
} // case 58
case 66: {
input.readMessage(
getDirectReadAckFieldBuilder().getBuilder(),
extensionRegistry);
clientMessageCase_ = 8;
break;
} // case 66
default: {
if (!super.parseUnknownField(input, extensionRegistry, tag)) {
done = true; // was an endgroup tag
}
break;
} // default:
} // switch (tag)
} // while (!done)
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.unwrapIOException();
} finally {
onChanged();
} // finally
return this;
}
private int clientMessageCase_ = 0;
private java.lang.Object clientMessage_;
public ClientMessageCase
getClientMessageCase() {
return ClientMessageCase.forNumber(
clientMessageCase_);
}
public Builder clearClientMessage() {
clientMessageCase_ = 0;
clientMessage_ = null;
onChanged();
return this;
}
private int bitField0_;
private com.google.protobuf.SingleFieldBuilderV3<
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest.Builder, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequestOrBuilder> initRequestBuilder_;
/**
*
* Client requests.
*
*
* .Ydb.Topic.StreamReadMessage.InitRequest init_request = 1;
* @return Whether the initRequest field is set.
*/
@java.lang.Override
public boolean hasInitRequest() {
return clientMessageCase_ == 1;
}
/**
*
* Client requests.
*
*
* .Ydb.Topic.StreamReadMessage.InitRequest init_request = 1;
* @return The initRequest.
*/
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest getInitRequest() {
if (initRequestBuilder_ == null) {
if (clientMessageCase_ == 1) {
return (tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest) clientMessage_;
}
return tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest.getDefaultInstance();
} else {
if (clientMessageCase_ == 1) {
return initRequestBuilder_.getMessage();
}
return tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest.getDefaultInstance();
}
}
/**
*
* Client requests.
*
*
* .Ydb.Topic.StreamReadMessage.InitRequest init_request = 1;
*/
public Builder setInitRequest(tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest value) {
if (initRequestBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
clientMessage_ = value;
onChanged();
} else {
initRequestBuilder_.setMessage(value);
}
clientMessageCase_ = 1;
return this;
}
/**
*
* Client requests.
*
*
* .Ydb.Topic.StreamReadMessage.InitRequest init_request = 1;
*/
public Builder setInitRequest(
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest.Builder builderForValue) {
if (initRequestBuilder_ == null) {
clientMessage_ = builderForValue.build();
onChanged();
} else {
initRequestBuilder_.setMessage(builderForValue.build());
}
clientMessageCase_ = 1;
return this;
}
/**
*
* Client requests.
*
*
* .Ydb.Topic.StreamReadMessage.InitRequest init_request = 1;
*/
public Builder mergeInitRequest(tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest value) {
if (initRequestBuilder_ == null) {
if (clientMessageCase_ == 1 &&
clientMessage_ != tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest.getDefaultInstance()) {
clientMessage_ = tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest.newBuilder((tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest) clientMessage_)
.mergeFrom(value).buildPartial();
} else {
clientMessage_ = value;
}
onChanged();
} else {
if (clientMessageCase_ == 1) {
initRequestBuilder_.mergeFrom(value);
} else {
initRequestBuilder_.setMessage(value);
}
}
clientMessageCase_ = 1;
return this;
}
/**
*
* Client requests.
*
*
* .Ydb.Topic.StreamReadMessage.InitRequest init_request = 1;
*/
public Builder clearInitRequest() {
if (initRequestBuilder_ == null) {
if (clientMessageCase_ == 1) {
clientMessageCase_ = 0;
clientMessage_ = null;
onChanged();
}
} else {
if (clientMessageCase_ == 1) {
clientMessageCase_ = 0;
clientMessage_ = null;
}
initRequestBuilder_.clear();
}
return this;
}
/**
*
* Client requests.
*
*
* .Ydb.Topic.StreamReadMessage.InitRequest init_request = 1;
*/
public tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest.Builder getInitRequestBuilder() {
return getInitRequestFieldBuilder().getBuilder();
}
/**
*
* Client requests.
*
*
* .Ydb.Topic.StreamReadMessage.InitRequest init_request = 1;
*/
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequestOrBuilder getInitRequestOrBuilder() {
if ((clientMessageCase_ == 1) && (initRequestBuilder_ != null)) {
return initRequestBuilder_.getMessageOrBuilder();
} else {
if (clientMessageCase_ == 1) {
return (tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest) clientMessage_;
}
return tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest.getDefaultInstance();
}
}
/**
*
* Client requests.
*
*
* .Ydb.Topic.StreamReadMessage.InitRequest init_request = 1;
*/
private com.google.protobuf.SingleFieldBuilderV3<
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest.Builder, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequestOrBuilder>
getInitRequestFieldBuilder() {
if (initRequestBuilder_ == null) {
if (!(clientMessageCase_ == 1)) {
clientMessage_ = tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest.getDefaultInstance();
}
initRequestBuilder_ = new com.google.protobuf.SingleFieldBuilderV3<
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest.Builder, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequestOrBuilder>(
(tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest) clientMessage_,
getParentForChildren(),
isClean());
clientMessage_ = null;
}
clientMessageCase_ = 1;
onChanged();
return initRequestBuilder_;
}
private com.google.protobuf.SingleFieldBuilderV3<
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadRequest, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadRequest.Builder, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadRequestOrBuilder> readRequestBuilder_;
/**
* .Ydb.Topic.StreamReadMessage.ReadRequest read_request = 2;
* @return Whether the readRequest field is set.
*/
@java.lang.Override
public boolean hasReadRequest() {
return clientMessageCase_ == 2;
}
/**
* .Ydb.Topic.StreamReadMessage.ReadRequest read_request = 2;
* @return The readRequest.
*/
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadRequest getReadRequest() {
if (readRequestBuilder_ == null) {
if (clientMessageCase_ == 2) {
return (tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadRequest) clientMessage_;
}
return tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadRequest.getDefaultInstance();
} else {
if (clientMessageCase_ == 2) {
return readRequestBuilder_.getMessage();
}
return tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadRequest.getDefaultInstance();
}
}
/**
* .Ydb.Topic.StreamReadMessage.ReadRequest read_request = 2;
*/
public Builder setReadRequest(tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadRequest value) {
if (readRequestBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
clientMessage_ = value;
onChanged();
} else {
readRequestBuilder_.setMessage(value);
}
clientMessageCase_ = 2;
return this;
}
/**
* .Ydb.Topic.StreamReadMessage.ReadRequest read_request = 2;
*/
public Builder setReadRequest(
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadRequest.Builder builderForValue) {
if (readRequestBuilder_ == null) {
clientMessage_ = builderForValue.build();
onChanged();
} else {
readRequestBuilder_.setMessage(builderForValue.build());
}
clientMessageCase_ = 2;
return this;
}
/**
* .Ydb.Topic.StreamReadMessage.ReadRequest read_request = 2;
*/
public Builder mergeReadRequest(tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadRequest value) {
if (readRequestBuilder_ == null) {
if (clientMessageCase_ == 2 &&
clientMessage_ != tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadRequest.getDefaultInstance()) {
clientMessage_ = tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadRequest.newBuilder((tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadRequest) clientMessage_)
.mergeFrom(value).buildPartial();
} else {
clientMessage_ = value;
}
onChanged();
} else {
if (clientMessageCase_ == 2) {
readRequestBuilder_.mergeFrom(value);
} else {
readRequestBuilder_.setMessage(value);
}
}
clientMessageCase_ = 2;
return this;
}
/**
* .Ydb.Topic.StreamReadMessage.ReadRequest read_request = 2;
*/
public Builder clearReadRequest() {
if (readRequestBuilder_ == null) {
if (clientMessageCase_ == 2) {
clientMessageCase_ = 0;
clientMessage_ = null;
onChanged();
}
} else {
if (clientMessageCase_ == 2) {
clientMessageCase_ = 0;
clientMessage_ = null;
}
readRequestBuilder_.clear();
}
return this;
}
/**
* .Ydb.Topic.StreamReadMessage.ReadRequest read_request = 2;
*/
public tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadRequest.Builder getReadRequestBuilder() {
return getReadRequestFieldBuilder().getBuilder();
}
/**
* .Ydb.Topic.StreamReadMessage.ReadRequest read_request = 2;
*/
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadRequestOrBuilder getReadRequestOrBuilder() {
if ((clientMessageCase_ == 2) && (readRequestBuilder_ != null)) {
return readRequestBuilder_.getMessageOrBuilder();
} else {
if (clientMessageCase_ == 2) {
return (tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadRequest) clientMessage_;
}
return tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadRequest.getDefaultInstance();
}
}
/**
* .Ydb.Topic.StreamReadMessage.ReadRequest read_request = 2;
*/
private com.google.protobuf.SingleFieldBuilderV3<
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadRequest, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadRequest.Builder, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadRequestOrBuilder>
getReadRequestFieldBuilder() {
if (readRequestBuilder_ == null) {
if (!(clientMessageCase_ == 2)) {
clientMessage_ = tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadRequest.getDefaultInstance();
}
readRequestBuilder_ = new com.google.protobuf.SingleFieldBuilderV3<
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadRequest, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadRequest.Builder, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadRequestOrBuilder>(
(tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadRequest) clientMessage_,
getParentForChildren(),
isClean());
clientMessage_ = null;
}
clientMessageCase_ = 2;
onChanged();
return readRequestBuilder_;
}
private com.google.protobuf.SingleFieldBuilderV3<
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.CommitOffsetRequest, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.CommitOffsetRequest.Builder, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.CommitOffsetRequestOrBuilder> commitOffsetRequestBuilder_;
/**
* .Ydb.Topic.StreamReadMessage.CommitOffsetRequest commit_offset_request = 3;
* @return Whether the commitOffsetRequest field is set.
*/
@java.lang.Override
public boolean hasCommitOffsetRequest() {
return clientMessageCase_ == 3;
}
/**
* .Ydb.Topic.StreamReadMessage.CommitOffsetRequest commit_offset_request = 3;
* @return The commitOffsetRequest.
*/
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamReadMessage.CommitOffsetRequest getCommitOffsetRequest() {
if (commitOffsetRequestBuilder_ == null) {
if (clientMessageCase_ == 3) {
return (tech.ydb.proto.topic.YdbTopic.StreamReadMessage.CommitOffsetRequest) clientMessage_;
}
return tech.ydb.proto.topic.YdbTopic.StreamReadMessage.CommitOffsetRequest.getDefaultInstance();
} else {
if (clientMessageCase_ == 3) {
return commitOffsetRequestBuilder_.getMessage();
}
return tech.ydb.proto.topic.YdbTopic.StreamReadMessage.CommitOffsetRequest.getDefaultInstance();
}
}
/**
* .Ydb.Topic.StreamReadMessage.CommitOffsetRequest commit_offset_request = 3;
*/
public Builder setCommitOffsetRequest(tech.ydb.proto.topic.YdbTopic.StreamReadMessage.CommitOffsetRequest value) {
if (commitOffsetRequestBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
clientMessage_ = value;
onChanged();
} else {
commitOffsetRequestBuilder_.setMessage(value);
}
clientMessageCase_ = 3;
return this;
}
/**
* .Ydb.Topic.StreamReadMessage.CommitOffsetRequest commit_offset_request = 3;
*/
public Builder setCommitOffsetRequest(
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.CommitOffsetRequest.Builder builderForValue) {
if (commitOffsetRequestBuilder_ == null) {
clientMessage_ = builderForValue.build();
onChanged();
} else {
commitOffsetRequestBuilder_.setMessage(builderForValue.build());
}
clientMessageCase_ = 3;
return this;
}
/**
* .Ydb.Topic.StreamReadMessage.CommitOffsetRequest commit_offset_request = 3;
*/
public Builder mergeCommitOffsetRequest(tech.ydb.proto.topic.YdbTopic.StreamReadMessage.CommitOffsetRequest value) {
if (commitOffsetRequestBuilder_ == null) {
if (clientMessageCase_ == 3 &&
clientMessage_ != tech.ydb.proto.topic.YdbTopic.StreamReadMessage.CommitOffsetRequest.getDefaultInstance()) {
clientMessage_ = tech.ydb.proto.topic.YdbTopic.StreamReadMessage.CommitOffsetRequest.newBuilder((tech.ydb.proto.topic.YdbTopic.StreamReadMessage.CommitOffsetRequest) clientMessage_)
.mergeFrom(value).buildPartial();
} else {
clientMessage_ = value;
}
onChanged();
} else {
if (clientMessageCase_ == 3) {
commitOffsetRequestBuilder_.mergeFrom(value);
} else {
commitOffsetRequestBuilder_.setMessage(value);
}
}
clientMessageCase_ = 3;
return this;
}
/**
* .Ydb.Topic.StreamReadMessage.CommitOffsetRequest commit_offset_request = 3;
*/
public Builder clearCommitOffsetRequest() {
if (commitOffsetRequestBuilder_ == null) {
if (clientMessageCase_ == 3) {
clientMessageCase_ = 0;
clientMessage_ = null;
onChanged();
}
} else {
if (clientMessageCase_ == 3) {
clientMessageCase_ = 0;
clientMessage_ = null;
}
commitOffsetRequestBuilder_.clear();
}
return this;
}
/**
* .Ydb.Topic.StreamReadMessage.CommitOffsetRequest commit_offset_request = 3;
*/
public tech.ydb.proto.topic.YdbTopic.StreamReadMessage.CommitOffsetRequest.Builder getCommitOffsetRequestBuilder() {
return getCommitOffsetRequestFieldBuilder().getBuilder();
}
/**
* .Ydb.Topic.StreamReadMessage.CommitOffsetRequest commit_offset_request = 3;
*/
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamReadMessage.CommitOffsetRequestOrBuilder getCommitOffsetRequestOrBuilder() {
if ((clientMessageCase_ == 3) && (commitOffsetRequestBuilder_ != null)) {
return commitOffsetRequestBuilder_.getMessageOrBuilder();
} else {
if (clientMessageCase_ == 3) {
return (tech.ydb.proto.topic.YdbTopic.StreamReadMessage.CommitOffsetRequest) clientMessage_;
}
return tech.ydb.proto.topic.YdbTopic.StreamReadMessage.CommitOffsetRequest.getDefaultInstance();
}
}
/**
* .Ydb.Topic.StreamReadMessage.CommitOffsetRequest commit_offset_request = 3;
*/
private com.google.protobuf.SingleFieldBuilderV3<
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.CommitOffsetRequest, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.CommitOffsetRequest.Builder, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.CommitOffsetRequestOrBuilder>
getCommitOffsetRequestFieldBuilder() {
if (commitOffsetRequestBuilder_ == null) {
if (!(clientMessageCase_ == 3)) {
clientMessage_ = tech.ydb.proto.topic.YdbTopic.StreamReadMessage.CommitOffsetRequest.getDefaultInstance();
}
commitOffsetRequestBuilder_ = new com.google.protobuf.SingleFieldBuilderV3<
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.CommitOffsetRequest, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.CommitOffsetRequest.Builder, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.CommitOffsetRequestOrBuilder>(
(tech.ydb.proto.topic.YdbTopic.StreamReadMessage.CommitOffsetRequest) clientMessage_,
getParentForChildren(),
isClean());
clientMessage_ = null;
}
clientMessageCase_ = 3;
onChanged();
return commitOffsetRequestBuilder_;
}
private com.google.protobuf.SingleFieldBuilderV3<
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.PartitionSessionStatusRequest, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.PartitionSessionStatusRequest.Builder, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.PartitionSessionStatusRequestOrBuilder> partitionSessionStatusRequestBuilder_;
/**
* .Ydb.Topic.StreamReadMessage.PartitionSessionStatusRequest partition_session_status_request = 4;
* @return Whether the partitionSessionStatusRequest field is set.
*/
@java.lang.Override
public boolean hasPartitionSessionStatusRequest() {
return clientMessageCase_ == 4;
}
/**
* .Ydb.Topic.StreamReadMessage.PartitionSessionStatusRequest partition_session_status_request = 4;
* @return The partitionSessionStatusRequest.
*/
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamReadMessage.PartitionSessionStatusRequest getPartitionSessionStatusRequest() {
if (partitionSessionStatusRequestBuilder_ == null) {
if (clientMessageCase_ == 4) {
return (tech.ydb.proto.topic.YdbTopic.StreamReadMessage.PartitionSessionStatusRequest) clientMessage_;
}
return tech.ydb.proto.topic.YdbTopic.StreamReadMessage.PartitionSessionStatusRequest.getDefaultInstance();
} else {
if (clientMessageCase_ == 4) {
return partitionSessionStatusRequestBuilder_.getMessage();
}
return tech.ydb.proto.topic.YdbTopic.StreamReadMessage.PartitionSessionStatusRequest.getDefaultInstance();
}
}
/**
* .Ydb.Topic.StreamReadMessage.PartitionSessionStatusRequest partition_session_status_request = 4;
*/
public Builder setPartitionSessionStatusRequest(tech.ydb.proto.topic.YdbTopic.StreamReadMessage.PartitionSessionStatusRequest value) {
if (partitionSessionStatusRequestBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
clientMessage_ = value;
onChanged();
} else {
partitionSessionStatusRequestBuilder_.setMessage(value);
}
clientMessageCase_ = 4;
return this;
}
/**
* .Ydb.Topic.StreamReadMessage.PartitionSessionStatusRequest partition_session_status_request = 4;
*/
public Builder setPartitionSessionStatusRequest(
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.PartitionSessionStatusRequest.Builder builderForValue) {
if (partitionSessionStatusRequestBuilder_ == null) {
clientMessage_ = builderForValue.build();
onChanged();
} else {
partitionSessionStatusRequestBuilder_.setMessage(builderForValue.build());
}
clientMessageCase_ = 4;
return this;
}
/**
* .Ydb.Topic.StreamReadMessage.PartitionSessionStatusRequest partition_session_status_request = 4;
*/
public Builder mergePartitionSessionStatusRequest(tech.ydb.proto.topic.YdbTopic.StreamReadMessage.PartitionSessionStatusRequest value) {
if (partitionSessionStatusRequestBuilder_ == null) {
if (clientMessageCase_ == 4 &&
clientMessage_ != tech.ydb.proto.topic.YdbTopic.StreamReadMessage.PartitionSessionStatusRequest.getDefaultInstance()) {
clientMessage_ = tech.ydb.proto.topic.YdbTopic.StreamReadMessage.PartitionSessionStatusRequest.newBuilder((tech.ydb.proto.topic.YdbTopic.StreamReadMessage.PartitionSessionStatusRequest) clientMessage_)
.mergeFrom(value).buildPartial();
} else {
clientMessage_ = value;
}
onChanged();
} else {
if (clientMessageCase_ == 4) {
partitionSessionStatusRequestBuilder_.mergeFrom(value);
} else {
partitionSessionStatusRequestBuilder_.setMessage(value);
}
}
clientMessageCase_ = 4;
return this;
}
/**
* .Ydb.Topic.StreamReadMessage.PartitionSessionStatusRequest partition_session_status_request = 4;
*/
public Builder clearPartitionSessionStatusRequest() {
if (partitionSessionStatusRequestBuilder_ == null) {
if (clientMessageCase_ == 4) {
clientMessageCase_ = 0;
clientMessage_ = null;
onChanged();
}
} else {
if (clientMessageCase_ == 4) {
clientMessageCase_ = 0;
clientMessage_ = null;
}
partitionSessionStatusRequestBuilder_.clear();
}
return this;
}
/**
* .Ydb.Topic.StreamReadMessage.PartitionSessionStatusRequest partition_session_status_request = 4;
*/
public tech.ydb.proto.topic.YdbTopic.StreamReadMessage.PartitionSessionStatusRequest.Builder getPartitionSessionStatusRequestBuilder() {
return getPartitionSessionStatusRequestFieldBuilder().getBuilder();
}
/**
* .Ydb.Topic.StreamReadMessage.PartitionSessionStatusRequest partition_session_status_request = 4;
*/
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamReadMessage.PartitionSessionStatusRequestOrBuilder getPartitionSessionStatusRequestOrBuilder() {
if ((clientMessageCase_ == 4) && (partitionSessionStatusRequestBuilder_ != null)) {
return partitionSessionStatusRequestBuilder_.getMessageOrBuilder();
} else {
if (clientMessageCase_ == 4) {
return (tech.ydb.proto.topic.YdbTopic.StreamReadMessage.PartitionSessionStatusRequest) clientMessage_;
}
return tech.ydb.proto.topic.YdbTopic.StreamReadMessage.PartitionSessionStatusRequest.getDefaultInstance();
}
}
/**
* .Ydb.Topic.StreamReadMessage.PartitionSessionStatusRequest partition_session_status_request = 4;
*/
private com.google.protobuf.SingleFieldBuilderV3<
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.PartitionSessionStatusRequest, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.PartitionSessionStatusRequest.Builder, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.PartitionSessionStatusRequestOrBuilder>
getPartitionSessionStatusRequestFieldBuilder() {
if (partitionSessionStatusRequestBuilder_ == null) {
if (!(clientMessageCase_ == 4)) {
clientMessage_ = tech.ydb.proto.topic.YdbTopic.StreamReadMessage.PartitionSessionStatusRequest.getDefaultInstance();
}
partitionSessionStatusRequestBuilder_ = new com.google.protobuf.SingleFieldBuilderV3<
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.PartitionSessionStatusRequest, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.PartitionSessionStatusRequest.Builder, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.PartitionSessionStatusRequestOrBuilder>(
(tech.ydb.proto.topic.YdbTopic.StreamReadMessage.PartitionSessionStatusRequest) clientMessage_,
getParentForChildren(),
isClean());
clientMessage_ = null;
}
clientMessageCase_ = 4;
onChanged();
return partitionSessionStatusRequestBuilder_;
}
private com.google.protobuf.SingleFieldBuilderV3<
tech.ydb.proto.topic.YdbTopic.UpdateTokenRequest, tech.ydb.proto.topic.YdbTopic.UpdateTokenRequest.Builder, tech.ydb.proto.topic.YdbTopic.UpdateTokenRequestOrBuilder> updateTokenRequestBuilder_;
/**
* .Ydb.Topic.UpdateTokenRequest update_token_request = 5;
* @return Whether the updateTokenRequest field is set.
*/
@java.lang.Override
public boolean hasUpdateTokenRequest() {
return clientMessageCase_ == 5;
}
/**
* .Ydb.Topic.UpdateTokenRequest update_token_request = 5;
* @return The updateTokenRequest.
*/
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.UpdateTokenRequest getUpdateTokenRequest() {
if (updateTokenRequestBuilder_ == null) {
if (clientMessageCase_ == 5) {
return (tech.ydb.proto.topic.YdbTopic.UpdateTokenRequest) clientMessage_;
}
return tech.ydb.proto.topic.YdbTopic.UpdateTokenRequest.getDefaultInstance();
} else {
if (clientMessageCase_ == 5) {
return updateTokenRequestBuilder_.getMessage();
}
return tech.ydb.proto.topic.YdbTopic.UpdateTokenRequest.getDefaultInstance();
}
}
/**
* .Ydb.Topic.UpdateTokenRequest update_token_request = 5;
*/
public Builder setUpdateTokenRequest(tech.ydb.proto.topic.YdbTopic.UpdateTokenRequest value) {
if (updateTokenRequestBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
clientMessage_ = value;
onChanged();
} else {
updateTokenRequestBuilder_.setMessage(value);
}
clientMessageCase_ = 5;
return this;
}
/**
* .Ydb.Topic.UpdateTokenRequest update_token_request = 5;
*/
public Builder setUpdateTokenRequest(
tech.ydb.proto.topic.YdbTopic.UpdateTokenRequest.Builder builderForValue) {
if (updateTokenRequestBuilder_ == null) {
clientMessage_ = builderForValue.build();
onChanged();
} else {
updateTokenRequestBuilder_.setMessage(builderForValue.build());
}
clientMessageCase_ = 5;
return this;
}
/**
* .Ydb.Topic.UpdateTokenRequest update_token_request = 5;
*/
public Builder mergeUpdateTokenRequest(tech.ydb.proto.topic.YdbTopic.UpdateTokenRequest value) {
if (updateTokenRequestBuilder_ == null) {
if (clientMessageCase_ == 5 &&
clientMessage_ != tech.ydb.proto.topic.YdbTopic.UpdateTokenRequest.getDefaultInstance()) {
clientMessage_ = tech.ydb.proto.topic.YdbTopic.UpdateTokenRequest.newBuilder((tech.ydb.proto.topic.YdbTopic.UpdateTokenRequest) clientMessage_)
.mergeFrom(value).buildPartial();
} else {
clientMessage_ = value;
}
onChanged();
} else {
if (clientMessageCase_ == 5) {
updateTokenRequestBuilder_.mergeFrom(value);
} else {
updateTokenRequestBuilder_.setMessage(value);
}
}
clientMessageCase_ = 5;
return this;
}
/**
* .Ydb.Topic.UpdateTokenRequest update_token_request = 5;
*/
public Builder clearUpdateTokenRequest() {
if (updateTokenRequestBuilder_ == null) {
if (clientMessageCase_ == 5) {
clientMessageCase_ = 0;
clientMessage_ = null;
onChanged();
}
} else {
if (clientMessageCase_ == 5) {
clientMessageCase_ = 0;
clientMessage_ = null;
}
updateTokenRequestBuilder_.clear();
}
return this;
}
/**
* .Ydb.Topic.UpdateTokenRequest update_token_request = 5;
*/
public tech.ydb.proto.topic.YdbTopic.UpdateTokenRequest.Builder getUpdateTokenRequestBuilder() {
return getUpdateTokenRequestFieldBuilder().getBuilder();
}
/**
* .Ydb.Topic.UpdateTokenRequest update_token_request = 5;
*/
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.UpdateTokenRequestOrBuilder getUpdateTokenRequestOrBuilder() {
if ((clientMessageCase_ == 5) && (updateTokenRequestBuilder_ != null)) {
return updateTokenRequestBuilder_.getMessageOrBuilder();
} else {
if (clientMessageCase_ == 5) {
return (tech.ydb.proto.topic.YdbTopic.UpdateTokenRequest) clientMessage_;
}
return tech.ydb.proto.topic.YdbTopic.UpdateTokenRequest.getDefaultInstance();
}
}
/**
* .Ydb.Topic.UpdateTokenRequest update_token_request = 5;
*/
private com.google.protobuf.SingleFieldBuilderV3<
tech.ydb.proto.topic.YdbTopic.UpdateTokenRequest, tech.ydb.proto.topic.YdbTopic.UpdateTokenRequest.Builder, tech.ydb.proto.topic.YdbTopic.UpdateTokenRequestOrBuilder>
getUpdateTokenRequestFieldBuilder() {
if (updateTokenRequestBuilder_ == null) {
if (!(clientMessageCase_ == 5)) {
clientMessage_ = tech.ydb.proto.topic.YdbTopic.UpdateTokenRequest.getDefaultInstance();
}
updateTokenRequestBuilder_ = new com.google.protobuf.SingleFieldBuilderV3<
tech.ydb.proto.topic.YdbTopic.UpdateTokenRequest, tech.ydb.proto.topic.YdbTopic.UpdateTokenRequest.Builder, tech.ydb.proto.topic.YdbTopic.UpdateTokenRequestOrBuilder>(
(tech.ydb.proto.topic.YdbTopic.UpdateTokenRequest) clientMessage_,
getParentForChildren(),
isClean());
clientMessage_ = null;
}
clientMessageCase_ = 5;
onChanged();
return updateTokenRequestBuilder_;
}
private com.google.protobuf.SingleFieldBuilderV3<
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.DirectReadAck, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.DirectReadAck.Builder, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.DirectReadAckOrBuilder> directReadAckBuilder_;
/**
* .Ydb.Topic.StreamReadMessage.DirectReadAck direct_read_ack = 8;
* @return Whether the directReadAck field is set.
*/
@java.lang.Override
public boolean hasDirectReadAck() {
return clientMessageCase_ == 8;
}
/**
* .Ydb.Topic.StreamReadMessage.DirectReadAck direct_read_ack = 8;
* @return The directReadAck.
*/
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamReadMessage.DirectReadAck getDirectReadAck() {
if (directReadAckBuilder_ == null) {
if (clientMessageCase_ == 8) {
return (tech.ydb.proto.topic.YdbTopic.StreamReadMessage.DirectReadAck) clientMessage_;
}
return tech.ydb.proto.topic.YdbTopic.StreamReadMessage.DirectReadAck.getDefaultInstance();
} else {
if (clientMessageCase_ == 8) {
return directReadAckBuilder_.getMessage();
}
return tech.ydb.proto.topic.YdbTopic.StreamReadMessage.DirectReadAck.getDefaultInstance();
}
}
/**
* .Ydb.Topic.StreamReadMessage.DirectReadAck direct_read_ack = 8;
*/
public Builder setDirectReadAck(tech.ydb.proto.topic.YdbTopic.StreamReadMessage.DirectReadAck value) {
if (directReadAckBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
clientMessage_ = value;
onChanged();
} else {
directReadAckBuilder_.setMessage(value);
}
clientMessageCase_ = 8;
return this;
}
/**
* .Ydb.Topic.StreamReadMessage.DirectReadAck direct_read_ack = 8;
*/
public Builder setDirectReadAck(
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.DirectReadAck.Builder builderForValue) {
if (directReadAckBuilder_ == null) {
clientMessage_ = builderForValue.build();
onChanged();
} else {
directReadAckBuilder_.setMessage(builderForValue.build());
}
clientMessageCase_ = 8;
return this;
}
/**
* .Ydb.Topic.StreamReadMessage.DirectReadAck direct_read_ack = 8;
*/
public Builder mergeDirectReadAck(tech.ydb.proto.topic.YdbTopic.StreamReadMessage.DirectReadAck value) {
if (directReadAckBuilder_ == null) {
if (clientMessageCase_ == 8 &&
clientMessage_ != tech.ydb.proto.topic.YdbTopic.StreamReadMessage.DirectReadAck.getDefaultInstance()) {
clientMessage_ = tech.ydb.proto.topic.YdbTopic.StreamReadMessage.DirectReadAck.newBuilder((tech.ydb.proto.topic.YdbTopic.StreamReadMessage.DirectReadAck) clientMessage_)
.mergeFrom(value).buildPartial();
} else {
clientMessage_ = value;
}
onChanged();
} else {
if (clientMessageCase_ == 8) {
directReadAckBuilder_.mergeFrom(value);
} else {
directReadAckBuilder_.setMessage(value);
}
}
clientMessageCase_ = 8;
return this;
}
/**
* .Ydb.Topic.StreamReadMessage.DirectReadAck direct_read_ack = 8;
*/
public Builder clearDirectReadAck() {
if (directReadAckBuilder_ == null) {
if (clientMessageCase_ == 8) {
clientMessageCase_ = 0;
clientMessage_ = null;
onChanged();
}
} else {
if (clientMessageCase_ == 8) {
clientMessageCase_ = 0;
clientMessage_ = null;
}
directReadAckBuilder_.clear();
}
return this;
}
/**
* .Ydb.Topic.StreamReadMessage.DirectReadAck direct_read_ack = 8;
*/
public tech.ydb.proto.topic.YdbTopic.StreamReadMessage.DirectReadAck.Builder getDirectReadAckBuilder() {
return getDirectReadAckFieldBuilder().getBuilder();
}
/**
* .Ydb.Topic.StreamReadMessage.DirectReadAck direct_read_ack = 8;
*/
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamReadMessage.DirectReadAckOrBuilder getDirectReadAckOrBuilder() {
if ((clientMessageCase_ == 8) && (directReadAckBuilder_ != null)) {
return directReadAckBuilder_.getMessageOrBuilder();
} else {
if (clientMessageCase_ == 8) {
return (tech.ydb.proto.topic.YdbTopic.StreamReadMessage.DirectReadAck) clientMessage_;
}
return tech.ydb.proto.topic.YdbTopic.StreamReadMessage.DirectReadAck.getDefaultInstance();
}
}
/**
* .Ydb.Topic.StreamReadMessage.DirectReadAck direct_read_ack = 8;
*/
private com.google.protobuf.SingleFieldBuilderV3<
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.DirectReadAck, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.DirectReadAck.Builder, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.DirectReadAckOrBuilder>
getDirectReadAckFieldBuilder() {
if (directReadAckBuilder_ == null) {
if (!(clientMessageCase_ == 8)) {
clientMessage_ = tech.ydb.proto.topic.YdbTopic.StreamReadMessage.DirectReadAck.getDefaultInstance();
}
directReadAckBuilder_ = new com.google.protobuf.SingleFieldBuilderV3<
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.DirectReadAck, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.DirectReadAck.Builder, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.DirectReadAckOrBuilder>(
(tech.ydb.proto.topic.YdbTopic.StreamReadMessage.DirectReadAck) clientMessage_,
getParentForChildren(),
isClean());
clientMessage_ = null;
}
clientMessageCase_ = 8;
onChanged();
return directReadAckBuilder_;
}
private com.google.protobuf.SingleFieldBuilderV3<
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StartPartitionSessionResponse, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StartPartitionSessionResponse.Builder, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StartPartitionSessionResponseOrBuilder> startPartitionSessionResponseBuilder_;
/**
*
* Responses to respective server commands.
*
*
* .Ydb.Topic.StreamReadMessage.StartPartitionSessionResponse start_partition_session_response = 6;
* @return Whether the startPartitionSessionResponse field is set.
*/
@java.lang.Override
public boolean hasStartPartitionSessionResponse() {
return clientMessageCase_ == 6;
}
/**
*
* Responses to respective server commands.
*
*
* .Ydb.Topic.StreamReadMessage.StartPartitionSessionResponse start_partition_session_response = 6;
* @return The startPartitionSessionResponse.
*/
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StartPartitionSessionResponse getStartPartitionSessionResponse() {
if (startPartitionSessionResponseBuilder_ == null) {
if (clientMessageCase_ == 6) {
return (tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StartPartitionSessionResponse) clientMessage_;
}
return tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StartPartitionSessionResponse.getDefaultInstance();
} else {
if (clientMessageCase_ == 6) {
return startPartitionSessionResponseBuilder_.getMessage();
}
return tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StartPartitionSessionResponse.getDefaultInstance();
}
}
/**
*
* Responses to respective server commands.
*
*
* .Ydb.Topic.StreamReadMessage.StartPartitionSessionResponse start_partition_session_response = 6;
*/
public Builder setStartPartitionSessionResponse(tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StartPartitionSessionResponse value) {
if (startPartitionSessionResponseBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
clientMessage_ = value;
onChanged();
} else {
startPartitionSessionResponseBuilder_.setMessage(value);
}
clientMessageCase_ = 6;
return this;
}
/**
*
* Responses to respective server commands.
*
*
* .Ydb.Topic.StreamReadMessage.StartPartitionSessionResponse start_partition_session_response = 6;
*/
public Builder setStartPartitionSessionResponse(
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StartPartitionSessionResponse.Builder builderForValue) {
if (startPartitionSessionResponseBuilder_ == null) {
clientMessage_ = builderForValue.build();
onChanged();
} else {
startPartitionSessionResponseBuilder_.setMessage(builderForValue.build());
}
clientMessageCase_ = 6;
return this;
}
/**
*
* Responses to respective server commands.
*
*
* .Ydb.Topic.StreamReadMessage.StartPartitionSessionResponse start_partition_session_response = 6;
*/
public Builder mergeStartPartitionSessionResponse(tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StartPartitionSessionResponse value) {
if (startPartitionSessionResponseBuilder_ == null) {
if (clientMessageCase_ == 6 &&
clientMessage_ != tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StartPartitionSessionResponse.getDefaultInstance()) {
clientMessage_ = tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StartPartitionSessionResponse.newBuilder((tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StartPartitionSessionResponse) clientMessage_)
.mergeFrom(value).buildPartial();
} else {
clientMessage_ = value;
}
onChanged();
} else {
if (clientMessageCase_ == 6) {
startPartitionSessionResponseBuilder_.mergeFrom(value);
} else {
startPartitionSessionResponseBuilder_.setMessage(value);
}
}
clientMessageCase_ = 6;
return this;
}
/**
*
* Responses to respective server commands.
*
*
* .Ydb.Topic.StreamReadMessage.StartPartitionSessionResponse start_partition_session_response = 6;
*/
public Builder clearStartPartitionSessionResponse() {
if (startPartitionSessionResponseBuilder_ == null) {
if (clientMessageCase_ == 6) {
clientMessageCase_ = 0;
clientMessage_ = null;
onChanged();
}
} else {
if (clientMessageCase_ == 6) {
clientMessageCase_ = 0;
clientMessage_ = null;
}
startPartitionSessionResponseBuilder_.clear();
}
return this;
}
/**
*
* Responses to respective server commands.
*
*
* .Ydb.Topic.StreamReadMessage.StartPartitionSessionResponse start_partition_session_response = 6;
*/
public tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StartPartitionSessionResponse.Builder getStartPartitionSessionResponseBuilder() {
return getStartPartitionSessionResponseFieldBuilder().getBuilder();
}
/**
*
* Responses to respective server commands.
*
*
* .Ydb.Topic.StreamReadMessage.StartPartitionSessionResponse start_partition_session_response = 6;
*/
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StartPartitionSessionResponseOrBuilder getStartPartitionSessionResponseOrBuilder() {
if ((clientMessageCase_ == 6) && (startPartitionSessionResponseBuilder_ != null)) {
return startPartitionSessionResponseBuilder_.getMessageOrBuilder();
} else {
if (clientMessageCase_ == 6) {
return (tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StartPartitionSessionResponse) clientMessage_;
}
return tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StartPartitionSessionResponse.getDefaultInstance();
}
}
/**
*
* Responses to respective server commands.
*
*
* .Ydb.Topic.StreamReadMessage.StartPartitionSessionResponse start_partition_session_response = 6;
*/
private com.google.protobuf.SingleFieldBuilderV3<
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StartPartitionSessionResponse, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StartPartitionSessionResponse.Builder, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StartPartitionSessionResponseOrBuilder>
getStartPartitionSessionResponseFieldBuilder() {
if (startPartitionSessionResponseBuilder_ == null) {
if (!(clientMessageCase_ == 6)) {
clientMessage_ = tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StartPartitionSessionResponse.getDefaultInstance();
}
startPartitionSessionResponseBuilder_ = new com.google.protobuf.SingleFieldBuilderV3<
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StartPartitionSessionResponse, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StartPartitionSessionResponse.Builder, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StartPartitionSessionResponseOrBuilder>(
(tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StartPartitionSessionResponse) clientMessage_,
getParentForChildren(),
isClean());
clientMessage_ = null;
}
clientMessageCase_ = 6;
onChanged();
return startPartitionSessionResponseBuilder_;
}
private com.google.protobuf.SingleFieldBuilderV3<
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StopPartitionSessionResponse, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StopPartitionSessionResponse.Builder, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StopPartitionSessionResponseOrBuilder> stopPartitionSessionResponseBuilder_;
/**
* .Ydb.Topic.StreamReadMessage.StopPartitionSessionResponse stop_partition_session_response = 7;
* @return Whether the stopPartitionSessionResponse field is set.
*/
@java.lang.Override
public boolean hasStopPartitionSessionResponse() {
return clientMessageCase_ == 7;
}
/**
* .Ydb.Topic.StreamReadMessage.StopPartitionSessionResponse stop_partition_session_response = 7;
* @return The stopPartitionSessionResponse.
*/
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StopPartitionSessionResponse getStopPartitionSessionResponse() {
if (stopPartitionSessionResponseBuilder_ == null) {
if (clientMessageCase_ == 7) {
return (tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StopPartitionSessionResponse) clientMessage_;
}
return tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StopPartitionSessionResponse.getDefaultInstance();
} else {
if (clientMessageCase_ == 7) {
return stopPartitionSessionResponseBuilder_.getMessage();
}
return tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StopPartitionSessionResponse.getDefaultInstance();
}
}
/**
* .Ydb.Topic.StreamReadMessage.StopPartitionSessionResponse stop_partition_session_response = 7;
*/
public Builder setStopPartitionSessionResponse(tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StopPartitionSessionResponse value) {
if (stopPartitionSessionResponseBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
clientMessage_ = value;
onChanged();
} else {
stopPartitionSessionResponseBuilder_.setMessage(value);
}
clientMessageCase_ = 7;
return this;
}
/**
* .Ydb.Topic.StreamReadMessage.StopPartitionSessionResponse stop_partition_session_response = 7;
*/
public Builder setStopPartitionSessionResponse(
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StopPartitionSessionResponse.Builder builderForValue) {
if (stopPartitionSessionResponseBuilder_ == null) {
clientMessage_ = builderForValue.build();
onChanged();
} else {
stopPartitionSessionResponseBuilder_.setMessage(builderForValue.build());
}
clientMessageCase_ = 7;
return this;
}
/**
* .Ydb.Topic.StreamReadMessage.StopPartitionSessionResponse stop_partition_session_response = 7;
*/
public Builder mergeStopPartitionSessionResponse(tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StopPartitionSessionResponse value) {
if (stopPartitionSessionResponseBuilder_ == null) {
if (clientMessageCase_ == 7 &&
clientMessage_ != tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StopPartitionSessionResponse.getDefaultInstance()) {
clientMessage_ = tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StopPartitionSessionResponse.newBuilder((tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StopPartitionSessionResponse) clientMessage_)
.mergeFrom(value).buildPartial();
} else {
clientMessage_ = value;
}
onChanged();
} else {
if (clientMessageCase_ == 7) {
stopPartitionSessionResponseBuilder_.mergeFrom(value);
} else {
stopPartitionSessionResponseBuilder_.setMessage(value);
}
}
clientMessageCase_ = 7;
return this;
}
/**
* .Ydb.Topic.StreamReadMessage.StopPartitionSessionResponse stop_partition_session_response = 7;
*/
public Builder clearStopPartitionSessionResponse() {
if (stopPartitionSessionResponseBuilder_ == null) {
if (clientMessageCase_ == 7) {
clientMessageCase_ = 0;
clientMessage_ = null;
onChanged();
}
} else {
if (clientMessageCase_ == 7) {
clientMessageCase_ = 0;
clientMessage_ = null;
}
stopPartitionSessionResponseBuilder_.clear();
}
return this;
}
/**
* .Ydb.Topic.StreamReadMessage.StopPartitionSessionResponse stop_partition_session_response = 7;
*/
public tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StopPartitionSessionResponse.Builder getStopPartitionSessionResponseBuilder() {
return getStopPartitionSessionResponseFieldBuilder().getBuilder();
}
/**
* .Ydb.Topic.StreamReadMessage.StopPartitionSessionResponse stop_partition_session_response = 7;
*/
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StopPartitionSessionResponseOrBuilder getStopPartitionSessionResponseOrBuilder() {
if ((clientMessageCase_ == 7) && (stopPartitionSessionResponseBuilder_ != null)) {
return stopPartitionSessionResponseBuilder_.getMessageOrBuilder();
} else {
if (clientMessageCase_ == 7) {
return (tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StopPartitionSessionResponse) clientMessage_;
}
return tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StopPartitionSessionResponse.getDefaultInstance();
}
}
/**
* .Ydb.Topic.StreamReadMessage.StopPartitionSessionResponse stop_partition_session_response = 7;
*/
private com.google.protobuf.SingleFieldBuilderV3<
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StopPartitionSessionResponse, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StopPartitionSessionResponse.Builder, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StopPartitionSessionResponseOrBuilder>
getStopPartitionSessionResponseFieldBuilder() {
if (stopPartitionSessionResponseBuilder_ == null) {
if (!(clientMessageCase_ == 7)) {
clientMessage_ = tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StopPartitionSessionResponse.getDefaultInstance();
}
stopPartitionSessionResponseBuilder_ = new com.google.protobuf.SingleFieldBuilderV3<
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StopPartitionSessionResponse, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StopPartitionSessionResponse.Builder, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StopPartitionSessionResponseOrBuilder>(
(tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StopPartitionSessionResponse) clientMessage_,
getParentForChildren(),
isClean());
clientMessage_ = null;
}
clientMessageCase_ = 7;
onChanged();
return stopPartitionSessionResponseBuilder_;
}
@java.lang.Override
public final Builder setUnknownFields(
final com.google.protobuf.UnknownFieldSet unknownFields) {
return super.setUnknownFields(unknownFields);
}
@java.lang.Override
public final Builder mergeUnknownFields(
final com.google.protobuf.UnknownFieldSet unknownFields) {
return super.mergeUnknownFields(unknownFields);
}
// @@protoc_insertion_point(builder_scope:Ydb.Topic.StreamReadMessage.FromClient)
}
// @@protoc_insertion_point(class_scope:Ydb.Topic.StreamReadMessage.FromClient)
private static final tech.ydb.proto.topic.YdbTopic.StreamReadMessage.FromClient DEFAULT_INSTANCE;
static {
DEFAULT_INSTANCE = new tech.ydb.proto.topic.YdbTopic.StreamReadMessage.FromClient();
}
public static tech.ydb.proto.topic.YdbTopic.StreamReadMessage.FromClient getDefaultInstance() {
return DEFAULT_INSTANCE;
}
private static final com.google.protobuf.Parser
PARSER = new com.google.protobuf.AbstractParser() {
@java.lang.Override
public FromClient parsePartialFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
Builder builder = newBuilder();
try {
builder.mergeFrom(input, extensionRegistry);
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.setUnfinishedMessage(builder.buildPartial());
} catch (com.google.protobuf.UninitializedMessageException e) {
throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial());
} catch (java.io.IOException e) {
throw new com.google.protobuf.InvalidProtocolBufferException(e)
.setUnfinishedMessage(builder.buildPartial());
}
return builder.buildPartial();
}
};
public static com.google.protobuf.Parser parser() {
return PARSER;
}
@java.lang.Override
public com.google.protobuf.Parser getParserForType() {
return PARSER;
}
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamReadMessage.FromClient getDefaultInstanceForType() {
return DEFAULT_INSTANCE;
}
}
public interface FromServerOrBuilder extends
// @@protoc_insertion_point(interface_extends:Ydb.Topic.StreamReadMessage.FromServer)
com.google.protobuf.MessageOrBuilder {
/**
*
* Server status of response.
*
*
* .Ydb.StatusIds.StatusCode status = 1;
* @return The enum numeric value on the wire for status.
*/
int getStatusValue();
/**
*
* Server status of response.
*
*
* .Ydb.StatusIds.StatusCode status = 1;
* @return The status.
*/
tech.ydb.proto.StatusCodesProtos.StatusIds.StatusCode getStatus();
/**
*
* Issues if any.
*
*
* repeated .Ydb.Issue.IssueMessage issues = 2;
*/
java.util.List
getIssuesList();
/**
*
* Issues if any.
*
*
* repeated .Ydb.Issue.IssueMessage issues = 2;
*/
tech.ydb.proto.YdbIssueMessage.IssueMessage getIssues(int index);
/**
*
* Issues if any.
*
*
* repeated .Ydb.Issue.IssueMessage issues = 2;
*/
int getIssuesCount();
/**
*
* Issues if any.
*
*
* repeated .Ydb.Issue.IssueMessage issues = 2;
*/
java.util.List extends tech.ydb.proto.YdbIssueMessage.IssueMessageOrBuilder>
getIssuesOrBuilderList();
/**
*
* Issues if any.
*
*
* repeated .Ydb.Issue.IssueMessage issues = 2;
*/
tech.ydb.proto.YdbIssueMessage.IssueMessageOrBuilder getIssuesOrBuilder(
int index);
/**
*
* Responses to respective client requests.
*
*
* .Ydb.Topic.StreamReadMessage.InitResponse init_response = 3;
* @return Whether the initResponse field is set.
*/
boolean hasInitResponse();
/**
*
* Responses to respective client requests.
*
*
* .Ydb.Topic.StreamReadMessage.InitResponse init_response = 3;
* @return The initResponse.
*/
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitResponse getInitResponse();
/**
*
* Responses to respective client requests.
*
*
* .Ydb.Topic.StreamReadMessage.InitResponse init_response = 3;
*/
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitResponseOrBuilder getInitResponseOrBuilder();
/**
* .Ydb.Topic.StreamReadMessage.ReadResponse read_response = 4;
* @return Whether the readResponse field is set.
*/
boolean hasReadResponse();
/**
* .Ydb.Topic.StreamReadMessage.ReadResponse read_response = 4;
* @return The readResponse.
*/
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse getReadResponse();
/**
* .Ydb.Topic.StreamReadMessage.ReadResponse read_response = 4;
*/
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponseOrBuilder getReadResponseOrBuilder();
/**
* .Ydb.Topic.StreamReadMessage.CommitOffsetResponse commit_offset_response = 5;
* @return Whether the commitOffsetResponse field is set.
*/
boolean hasCommitOffsetResponse();
/**
* .Ydb.Topic.StreamReadMessage.CommitOffsetResponse commit_offset_response = 5;
* @return The commitOffsetResponse.
*/
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.CommitOffsetResponse getCommitOffsetResponse();
/**
* .Ydb.Topic.StreamReadMessage.CommitOffsetResponse commit_offset_response = 5;
*/
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.CommitOffsetResponseOrBuilder getCommitOffsetResponseOrBuilder();
/**
* .Ydb.Topic.StreamReadMessage.PartitionSessionStatusResponse partition_session_status_response = 6;
* @return Whether the partitionSessionStatusResponse field is set.
*/
boolean hasPartitionSessionStatusResponse();
/**
* .Ydb.Topic.StreamReadMessage.PartitionSessionStatusResponse partition_session_status_response = 6;
* @return The partitionSessionStatusResponse.
*/
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.PartitionSessionStatusResponse getPartitionSessionStatusResponse();
/**
* .Ydb.Topic.StreamReadMessage.PartitionSessionStatusResponse partition_session_status_response = 6;
*/
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.PartitionSessionStatusResponseOrBuilder getPartitionSessionStatusResponseOrBuilder();
/**
* .Ydb.Topic.UpdateTokenResponse update_token_response = 7;
* @return Whether the updateTokenResponse field is set.
*/
boolean hasUpdateTokenResponse();
/**
* .Ydb.Topic.UpdateTokenResponse update_token_response = 7;
* @return The updateTokenResponse.
*/
tech.ydb.proto.topic.YdbTopic.UpdateTokenResponse getUpdateTokenResponse();
/**
* .Ydb.Topic.UpdateTokenResponse update_token_response = 7;
*/
tech.ydb.proto.topic.YdbTopic.UpdateTokenResponseOrBuilder getUpdateTokenResponseOrBuilder();
/**
*
* Server commands.
*
*
* .Ydb.Topic.StreamReadMessage.StartPartitionSessionRequest start_partition_session_request = 8;
* @return Whether the startPartitionSessionRequest field is set.
*/
boolean hasStartPartitionSessionRequest();
/**
*
* Server commands.
*
*
* .Ydb.Topic.StreamReadMessage.StartPartitionSessionRequest start_partition_session_request = 8;
* @return The startPartitionSessionRequest.
*/
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StartPartitionSessionRequest getStartPartitionSessionRequest();
/**
*
* Server commands.
*
*
* .Ydb.Topic.StreamReadMessage.StartPartitionSessionRequest start_partition_session_request = 8;
*/
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StartPartitionSessionRequestOrBuilder getStartPartitionSessionRequestOrBuilder();
/**
* .Ydb.Topic.StreamReadMessage.StopPartitionSessionRequest stop_partition_session_request = 9;
* @return Whether the stopPartitionSessionRequest field is set.
*/
boolean hasStopPartitionSessionRequest();
/**
* .Ydb.Topic.StreamReadMessage.StopPartitionSessionRequest stop_partition_session_request = 9;
* @return The stopPartitionSessionRequest.
*/
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StopPartitionSessionRequest getStopPartitionSessionRequest();
/**
* .Ydb.Topic.StreamReadMessage.StopPartitionSessionRequest stop_partition_session_request = 9;
*/
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StopPartitionSessionRequestOrBuilder getStopPartitionSessionRequestOrBuilder();
/**
* .Ydb.Topic.StreamReadMessage.UpdatePartitionSession update_partition_session = 10;
* @return Whether the updatePartitionSession field is set.
*/
boolean hasUpdatePartitionSession();
/**
* .Ydb.Topic.StreamReadMessage.UpdatePartitionSession update_partition_session = 10;
* @return The updatePartitionSession.
*/
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.UpdatePartitionSession getUpdatePartitionSession();
/**
* .Ydb.Topic.StreamReadMessage.UpdatePartitionSession update_partition_session = 10;
*/
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.UpdatePartitionSessionOrBuilder getUpdatePartitionSessionOrBuilder();
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.FromServer.ServerMessageCase getServerMessageCase();
}
/**
*
* Server-client message for read session. Contains one of:
* InitResponse - handshake response from server.
* ReadResponse - portion of data.
* CommitOffsetResponse - acknowledgment for commit.
* PartitionSessionStatusResponse - server response with partition session status.
* UpdateTokenResponse - acknowledgment of token update.
*
* StartPartitionSessionRequest - command from server to create a partition session.
* StopPartitionSessionRequest - command from server to destroy a partition session.
* UpdatePartitionSession - command from server to update a partition session.
*
*
* Protobuf type {@code Ydb.Topic.StreamReadMessage.FromServer}
*/
public static final class FromServer extends
com.google.protobuf.GeneratedMessageV3 implements
// @@protoc_insertion_point(message_implements:Ydb.Topic.StreamReadMessage.FromServer)
FromServerOrBuilder {
private static final long serialVersionUID = 0L;
// Use FromServer.newBuilder() to construct.
private FromServer(com.google.protobuf.GeneratedMessageV3.Builder> builder) {
super(builder);
}
private FromServer() {
status_ = 0;
issues_ = java.util.Collections.emptyList();
}
@java.lang.Override
@SuppressWarnings({"unused"})
protected java.lang.Object newInstance(
UnusedPrivateParameter unused) {
return new FromServer();
}
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_StreamReadMessage_FromServer_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_StreamReadMessage_FromServer_fieldAccessorTable
.ensureFieldAccessorsInitialized(
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.FromServer.class, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.FromServer.Builder.class);
}
private int serverMessageCase_ = 0;
@SuppressWarnings("serial")
private java.lang.Object serverMessage_;
public enum ServerMessageCase
implements com.google.protobuf.Internal.EnumLite,
com.google.protobuf.AbstractMessage.InternalOneOfEnum {
INIT_RESPONSE(3),
READ_RESPONSE(4),
COMMIT_OFFSET_RESPONSE(5),
PARTITION_SESSION_STATUS_RESPONSE(6),
UPDATE_TOKEN_RESPONSE(7),
START_PARTITION_SESSION_REQUEST(8),
STOP_PARTITION_SESSION_REQUEST(9),
UPDATE_PARTITION_SESSION(10),
SERVERMESSAGE_NOT_SET(0);
private final int value;
private ServerMessageCase(int value) {
this.value = value;
}
/**
* @param value The number of the enum to look for.
* @return The enum associated with the given number.
* @deprecated Use {@link #forNumber(int)} instead.
*/
@java.lang.Deprecated
public static ServerMessageCase valueOf(int value) {
return forNumber(value);
}
public static ServerMessageCase forNumber(int value) {
switch (value) {
case 3: return INIT_RESPONSE;
case 4: return READ_RESPONSE;
case 5: return COMMIT_OFFSET_RESPONSE;
case 6: return PARTITION_SESSION_STATUS_RESPONSE;
case 7: return UPDATE_TOKEN_RESPONSE;
case 8: return START_PARTITION_SESSION_REQUEST;
case 9: return STOP_PARTITION_SESSION_REQUEST;
case 10: return UPDATE_PARTITION_SESSION;
case 0: return SERVERMESSAGE_NOT_SET;
default: return null;
}
}
public int getNumber() {
return this.value;
}
};
public ServerMessageCase
getServerMessageCase() {
return ServerMessageCase.forNumber(
serverMessageCase_);
}
public static final int STATUS_FIELD_NUMBER = 1;
private int status_ = 0;
/**
*
* Server status of response.
*
*
* .Ydb.StatusIds.StatusCode status = 1;
* @return The enum numeric value on the wire for status.
*/
@java.lang.Override public int getStatusValue() {
return status_;
}
/**
*
* Server status of response.
*
*
* .Ydb.StatusIds.StatusCode status = 1;
* @return The status.
*/
@java.lang.Override public tech.ydb.proto.StatusCodesProtos.StatusIds.StatusCode getStatus() {
tech.ydb.proto.StatusCodesProtos.StatusIds.StatusCode result = tech.ydb.proto.StatusCodesProtos.StatusIds.StatusCode.forNumber(status_);
return result == null ? tech.ydb.proto.StatusCodesProtos.StatusIds.StatusCode.UNRECOGNIZED : result;
}
public static final int ISSUES_FIELD_NUMBER = 2;
@SuppressWarnings("serial")
private java.util.List issues_;
/**
*
* Issues if any.
*
*
* repeated .Ydb.Issue.IssueMessage issues = 2;
*/
@java.lang.Override
public java.util.List getIssuesList() {
return issues_;
}
/**
*
* Issues if any.
*
*
* repeated .Ydb.Issue.IssueMessage issues = 2;
*/
@java.lang.Override
public java.util.List extends tech.ydb.proto.YdbIssueMessage.IssueMessageOrBuilder>
getIssuesOrBuilderList() {
return issues_;
}
/**
*
* Issues if any.
*
*
* repeated .Ydb.Issue.IssueMessage issues = 2;
*/
@java.lang.Override
public int getIssuesCount() {
return issues_.size();
}
/**
*
* Issues if any.
*
*
* repeated .Ydb.Issue.IssueMessage issues = 2;
*/
@java.lang.Override
public tech.ydb.proto.YdbIssueMessage.IssueMessage getIssues(int index) {
return issues_.get(index);
}
/**
*
* Issues if any.
*
*
* repeated .Ydb.Issue.IssueMessage issues = 2;
*/
@java.lang.Override
public tech.ydb.proto.YdbIssueMessage.IssueMessageOrBuilder getIssuesOrBuilder(
int index) {
return issues_.get(index);
}
public static final int INIT_RESPONSE_FIELD_NUMBER = 3;
/**
*
* Responses to respective client requests.
*
*
* .Ydb.Topic.StreamReadMessage.InitResponse init_response = 3;
* @return Whether the initResponse field is set.
*/
@java.lang.Override
public boolean hasInitResponse() {
return serverMessageCase_ == 3;
}
/**
*
* Responses to respective client requests.
*
*
* .Ydb.Topic.StreamReadMessage.InitResponse init_response = 3;
* @return The initResponse.
*/
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitResponse getInitResponse() {
if (serverMessageCase_ == 3) {
return (tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitResponse) serverMessage_;
}
return tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitResponse.getDefaultInstance();
}
/**
*
* Responses to respective client requests.
*
*
* .Ydb.Topic.StreamReadMessage.InitResponse init_response = 3;
*/
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitResponseOrBuilder getInitResponseOrBuilder() {
if (serverMessageCase_ == 3) {
return (tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitResponse) serverMessage_;
}
return tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitResponse.getDefaultInstance();
}
public static final int READ_RESPONSE_FIELD_NUMBER = 4;
/**
* .Ydb.Topic.StreamReadMessage.ReadResponse read_response = 4;
* @return Whether the readResponse field is set.
*/
@java.lang.Override
public boolean hasReadResponse() {
return serverMessageCase_ == 4;
}
/**
* .Ydb.Topic.StreamReadMessage.ReadResponse read_response = 4;
* @return The readResponse.
*/
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse getReadResponse() {
if (serverMessageCase_ == 4) {
return (tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse) serverMessage_;
}
return tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.getDefaultInstance();
}
/**
* .Ydb.Topic.StreamReadMessage.ReadResponse read_response = 4;
*/
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponseOrBuilder getReadResponseOrBuilder() {
if (serverMessageCase_ == 4) {
return (tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse) serverMessage_;
}
return tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.getDefaultInstance();
}
public static final int COMMIT_OFFSET_RESPONSE_FIELD_NUMBER = 5;
/**
* .Ydb.Topic.StreamReadMessage.CommitOffsetResponse commit_offset_response = 5;
* @return Whether the commitOffsetResponse field is set.
*/
@java.lang.Override
public boolean hasCommitOffsetResponse() {
return serverMessageCase_ == 5;
}
/**
* .Ydb.Topic.StreamReadMessage.CommitOffsetResponse commit_offset_response = 5;
* @return The commitOffsetResponse.
*/
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamReadMessage.CommitOffsetResponse getCommitOffsetResponse() {
if (serverMessageCase_ == 5) {
return (tech.ydb.proto.topic.YdbTopic.StreamReadMessage.CommitOffsetResponse) serverMessage_;
}
return tech.ydb.proto.topic.YdbTopic.StreamReadMessage.CommitOffsetResponse.getDefaultInstance();
}
/**
* .Ydb.Topic.StreamReadMessage.CommitOffsetResponse commit_offset_response = 5;
*/
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamReadMessage.CommitOffsetResponseOrBuilder getCommitOffsetResponseOrBuilder() {
if (serverMessageCase_ == 5) {
return (tech.ydb.proto.topic.YdbTopic.StreamReadMessage.CommitOffsetResponse) serverMessage_;
}
return tech.ydb.proto.topic.YdbTopic.StreamReadMessage.CommitOffsetResponse.getDefaultInstance();
}
public static final int PARTITION_SESSION_STATUS_RESPONSE_FIELD_NUMBER = 6;
/**
* .Ydb.Topic.StreamReadMessage.PartitionSessionStatusResponse partition_session_status_response = 6;
* @return Whether the partitionSessionStatusResponse field is set.
*/
@java.lang.Override
public boolean hasPartitionSessionStatusResponse() {
return serverMessageCase_ == 6;
}
/**
* .Ydb.Topic.StreamReadMessage.PartitionSessionStatusResponse partition_session_status_response = 6;
* @return The partitionSessionStatusResponse.
*/
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamReadMessage.PartitionSessionStatusResponse getPartitionSessionStatusResponse() {
if (serverMessageCase_ == 6) {
return (tech.ydb.proto.topic.YdbTopic.StreamReadMessage.PartitionSessionStatusResponse) serverMessage_;
}
return tech.ydb.proto.topic.YdbTopic.StreamReadMessage.PartitionSessionStatusResponse.getDefaultInstance();
}
/**
* .Ydb.Topic.StreamReadMessage.PartitionSessionStatusResponse partition_session_status_response = 6;
*/
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamReadMessage.PartitionSessionStatusResponseOrBuilder getPartitionSessionStatusResponseOrBuilder() {
if (serverMessageCase_ == 6) {
return (tech.ydb.proto.topic.YdbTopic.StreamReadMessage.PartitionSessionStatusResponse) serverMessage_;
}
return tech.ydb.proto.topic.YdbTopic.StreamReadMessage.PartitionSessionStatusResponse.getDefaultInstance();
}
public static final int UPDATE_TOKEN_RESPONSE_FIELD_NUMBER = 7;
/**
* .Ydb.Topic.UpdateTokenResponse update_token_response = 7;
* @return Whether the updateTokenResponse field is set.
*/
@java.lang.Override
public boolean hasUpdateTokenResponse() {
return serverMessageCase_ == 7;
}
/**
* .Ydb.Topic.UpdateTokenResponse update_token_response = 7;
* @return The updateTokenResponse.
*/
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.UpdateTokenResponse getUpdateTokenResponse() {
if (serverMessageCase_ == 7) {
return (tech.ydb.proto.topic.YdbTopic.UpdateTokenResponse) serverMessage_;
}
return tech.ydb.proto.topic.YdbTopic.UpdateTokenResponse.getDefaultInstance();
}
/**
* .Ydb.Topic.UpdateTokenResponse update_token_response = 7;
*/
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.UpdateTokenResponseOrBuilder getUpdateTokenResponseOrBuilder() {
if (serverMessageCase_ == 7) {
return (tech.ydb.proto.topic.YdbTopic.UpdateTokenResponse) serverMessage_;
}
return tech.ydb.proto.topic.YdbTopic.UpdateTokenResponse.getDefaultInstance();
}
public static final int START_PARTITION_SESSION_REQUEST_FIELD_NUMBER = 8;
/**
*
* Server commands.
*
*
* .Ydb.Topic.StreamReadMessage.StartPartitionSessionRequest start_partition_session_request = 8;
* @return Whether the startPartitionSessionRequest field is set.
*/
@java.lang.Override
public boolean hasStartPartitionSessionRequest() {
return serverMessageCase_ == 8;
}
/**
*
* Server commands.
*
*
* .Ydb.Topic.StreamReadMessage.StartPartitionSessionRequest start_partition_session_request = 8;
* @return The startPartitionSessionRequest.
*/
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StartPartitionSessionRequest getStartPartitionSessionRequest() {
if (serverMessageCase_ == 8) {
return (tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StartPartitionSessionRequest) serverMessage_;
}
return tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StartPartitionSessionRequest.getDefaultInstance();
}
/**
*
* Server commands.
*
*
* .Ydb.Topic.StreamReadMessage.StartPartitionSessionRequest start_partition_session_request = 8;
*/
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StartPartitionSessionRequestOrBuilder getStartPartitionSessionRequestOrBuilder() {
if (serverMessageCase_ == 8) {
return (tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StartPartitionSessionRequest) serverMessage_;
}
return tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StartPartitionSessionRequest.getDefaultInstance();
}
public static final int STOP_PARTITION_SESSION_REQUEST_FIELD_NUMBER = 9;
/**
* .Ydb.Topic.StreamReadMessage.StopPartitionSessionRequest stop_partition_session_request = 9;
* @return Whether the stopPartitionSessionRequest field is set.
*/
@java.lang.Override
public boolean hasStopPartitionSessionRequest() {
return serverMessageCase_ == 9;
}
/**
* .Ydb.Topic.StreamReadMessage.StopPartitionSessionRequest stop_partition_session_request = 9;
* @return The stopPartitionSessionRequest.
*/
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StopPartitionSessionRequest getStopPartitionSessionRequest() {
if (serverMessageCase_ == 9) {
return (tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StopPartitionSessionRequest) serverMessage_;
}
return tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StopPartitionSessionRequest.getDefaultInstance();
}
/**
* .Ydb.Topic.StreamReadMessage.StopPartitionSessionRequest stop_partition_session_request = 9;
*/
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StopPartitionSessionRequestOrBuilder getStopPartitionSessionRequestOrBuilder() {
if (serverMessageCase_ == 9) {
return (tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StopPartitionSessionRequest) serverMessage_;
}
return tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StopPartitionSessionRequest.getDefaultInstance();
}
public static final int UPDATE_PARTITION_SESSION_FIELD_NUMBER = 10;
/**
* .Ydb.Topic.StreamReadMessage.UpdatePartitionSession update_partition_session = 10;
* @return Whether the updatePartitionSession field is set.
*/
@java.lang.Override
public boolean hasUpdatePartitionSession() {
return serverMessageCase_ == 10;
}
/**
* .Ydb.Topic.StreamReadMessage.UpdatePartitionSession update_partition_session = 10;
* @return The updatePartitionSession.
*/
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamReadMessage.UpdatePartitionSession getUpdatePartitionSession() {
if (serverMessageCase_ == 10) {
return (tech.ydb.proto.topic.YdbTopic.StreamReadMessage.UpdatePartitionSession) serverMessage_;
}
return tech.ydb.proto.topic.YdbTopic.StreamReadMessage.UpdatePartitionSession.getDefaultInstance();
}
/**
* .Ydb.Topic.StreamReadMessage.UpdatePartitionSession update_partition_session = 10;
*/
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamReadMessage.UpdatePartitionSessionOrBuilder getUpdatePartitionSessionOrBuilder() {
if (serverMessageCase_ == 10) {
return (tech.ydb.proto.topic.YdbTopic.StreamReadMessage.UpdatePartitionSession) serverMessage_;
}
return tech.ydb.proto.topic.YdbTopic.StreamReadMessage.UpdatePartitionSession.getDefaultInstance();
}
private byte memoizedIsInitialized = -1;
@java.lang.Override
public final boolean isInitialized() {
byte isInitialized = memoizedIsInitialized;
if (isInitialized == 1) return true;
if (isInitialized == 0) return false;
memoizedIsInitialized = 1;
return true;
}
@java.lang.Override
public void writeTo(com.google.protobuf.CodedOutputStream output)
throws java.io.IOException {
if (status_ != tech.ydb.proto.StatusCodesProtos.StatusIds.StatusCode.STATUS_CODE_UNSPECIFIED.getNumber()) {
output.writeEnum(1, status_);
}
for (int i = 0; i < issues_.size(); i++) {
output.writeMessage(2, issues_.get(i));
}
if (serverMessageCase_ == 3) {
output.writeMessage(3, (tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitResponse) serverMessage_);
}
if (serverMessageCase_ == 4) {
output.writeMessage(4, (tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse) serverMessage_);
}
if (serverMessageCase_ == 5) {
output.writeMessage(5, (tech.ydb.proto.topic.YdbTopic.StreamReadMessage.CommitOffsetResponse) serverMessage_);
}
if (serverMessageCase_ == 6) {
output.writeMessage(6, (tech.ydb.proto.topic.YdbTopic.StreamReadMessage.PartitionSessionStatusResponse) serverMessage_);
}
if (serverMessageCase_ == 7) {
output.writeMessage(7, (tech.ydb.proto.topic.YdbTopic.UpdateTokenResponse) serverMessage_);
}
if (serverMessageCase_ == 8) {
output.writeMessage(8, (tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StartPartitionSessionRequest) serverMessage_);
}
if (serverMessageCase_ == 9) {
output.writeMessage(9, (tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StopPartitionSessionRequest) serverMessage_);
}
if (serverMessageCase_ == 10) {
output.writeMessage(10, (tech.ydb.proto.topic.YdbTopic.StreamReadMessage.UpdatePartitionSession) serverMessage_);
}
getUnknownFields().writeTo(output);
}
@java.lang.Override
public int getSerializedSize() {
int size = memoizedSize;
if (size != -1) return size;
size = 0;
if (status_ != tech.ydb.proto.StatusCodesProtos.StatusIds.StatusCode.STATUS_CODE_UNSPECIFIED.getNumber()) {
size += com.google.protobuf.CodedOutputStream
.computeEnumSize(1, status_);
}
for (int i = 0; i < issues_.size(); i++) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(2, issues_.get(i));
}
if (serverMessageCase_ == 3) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(3, (tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitResponse) serverMessage_);
}
if (serverMessageCase_ == 4) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(4, (tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse) serverMessage_);
}
if (serverMessageCase_ == 5) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(5, (tech.ydb.proto.topic.YdbTopic.StreamReadMessage.CommitOffsetResponse) serverMessage_);
}
if (serverMessageCase_ == 6) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(6, (tech.ydb.proto.topic.YdbTopic.StreamReadMessage.PartitionSessionStatusResponse) serverMessage_);
}
if (serverMessageCase_ == 7) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(7, (tech.ydb.proto.topic.YdbTopic.UpdateTokenResponse) serverMessage_);
}
if (serverMessageCase_ == 8) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(8, (tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StartPartitionSessionRequest) serverMessage_);
}
if (serverMessageCase_ == 9) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(9, (tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StopPartitionSessionRequest) serverMessage_);
}
if (serverMessageCase_ == 10) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(10, (tech.ydb.proto.topic.YdbTopic.StreamReadMessage.UpdatePartitionSession) serverMessage_);
}
size += getUnknownFields().getSerializedSize();
memoizedSize = size;
return size;
}
@java.lang.Override
public boolean equals(final java.lang.Object obj) {
if (obj == this) {
return true;
}
if (!(obj instanceof tech.ydb.proto.topic.YdbTopic.StreamReadMessage.FromServer)) {
return super.equals(obj);
}
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.FromServer other = (tech.ydb.proto.topic.YdbTopic.StreamReadMessage.FromServer) obj;
if (status_ != other.status_) return false;
if (!getIssuesList()
.equals(other.getIssuesList())) return false;
if (!getServerMessageCase().equals(other.getServerMessageCase())) return false;
switch (serverMessageCase_) {
case 3:
if (!getInitResponse()
.equals(other.getInitResponse())) return false;
break;
case 4:
if (!getReadResponse()
.equals(other.getReadResponse())) return false;
break;
case 5:
if (!getCommitOffsetResponse()
.equals(other.getCommitOffsetResponse())) return false;
break;
case 6:
if (!getPartitionSessionStatusResponse()
.equals(other.getPartitionSessionStatusResponse())) return false;
break;
case 7:
if (!getUpdateTokenResponse()
.equals(other.getUpdateTokenResponse())) return false;
break;
case 8:
if (!getStartPartitionSessionRequest()
.equals(other.getStartPartitionSessionRequest())) return false;
break;
case 9:
if (!getStopPartitionSessionRequest()
.equals(other.getStopPartitionSessionRequest())) return false;
break;
case 10:
if (!getUpdatePartitionSession()
.equals(other.getUpdatePartitionSession())) return false;
break;
case 0:
default:
}
if (!getUnknownFields().equals(other.getUnknownFields())) return false;
return true;
}
@java.lang.Override
public int hashCode() {
if (memoizedHashCode != 0) {
return memoizedHashCode;
}
int hash = 41;
hash = (19 * hash) + getDescriptor().hashCode();
hash = (37 * hash) + STATUS_FIELD_NUMBER;
hash = (53 * hash) + status_;
if (getIssuesCount() > 0) {
hash = (37 * hash) + ISSUES_FIELD_NUMBER;
hash = (53 * hash) + getIssuesList().hashCode();
}
switch (serverMessageCase_) {
case 3:
hash = (37 * hash) + INIT_RESPONSE_FIELD_NUMBER;
hash = (53 * hash) + getInitResponse().hashCode();
break;
case 4:
hash = (37 * hash) + READ_RESPONSE_FIELD_NUMBER;
hash = (53 * hash) + getReadResponse().hashCode();
break;
case 5:
hash = (37 * hash) + COMMIT_OFFSET_RESPONSE_FIELD_NUMBER;
hash = (53 * hash) + getCommitOffsetResponse().hashCode();
break;
case 6:
hash = (37 * hash) + PARTITION_SESSION_STATUS_RESPONSE_FIELD_NUMBER;
hash = (53 * hash) + getPartitionSessionStatusResponse().hashCode();
break;
case 7:
hash = (37 * hash) + UPDATE_TOKEN_RESPONSE_FIELD_NUMBER;
hash = (53 * hash) + getUpdateTokenResponse().hashCode();
break;
case 8:
hash = (37 * hash) + START_PARTITION_SESSION_REQUEST_FIELD_NUMBER;
hash = (53 * hash) + getStartPartitionSessionRequest().hashCode();
break;
case 9:
hash = (37 * hash) + STOP_PARTITION_SESSION_REQUEST_FIELD_NUMBER;
hash = (53 * hash) + getStopPartitionSessionRequest().hashCode();
break;
case 10:
hash = (37 * hash) + UPDATE_PARTITION_SESSION_FIELD_NUMBER;
hash = (53 * hash) + getUpdatePartitionSession().hashCode();
break;
case 0:
default:
}
hash = (29 * hash) + getUnknownFields().hashCode();
memoizedHashCode = hash;
return hash;
}
public static tech.ydb.proto.topic.YdbTopic.StreamReadMessage.FromServer parseFrom(
java.nio.ByteBuffer data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static tech.ydb.proto.topic.YdbTopic.StreamReadMessage.FromServer parseFrom(
java.nio.ByteBuffer data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.StreamReadMessage.FromServer parseFrom(
com.google.protobuf.ByteString data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static tech.ydb.proto.topic.YdbTopic.StreamReadMessage.FromServer parseFrom(
com.google.protobuf.ByteString data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.StreamReadMessage.FromServer parseFrom(byte[] data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static tech.ydb.proto.topic.YdbTopic.StreamReadMessage.FromServer parseFrom(
byte[] data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.StreamReadMessage.FromServer parseFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static tech.ydb.proto.topic.YdbTopic.StreamReadMessage.FromServer parseFrom(
java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.StreamReadMessage.FromServer parseDelimitedFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input);
}
public static tech.ydb.proto.topic.YdbTopic.StreamReadMessage.FromServer parseDelimitedFrom(
java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.StreamReadMessage.FromServer parseFrom(
com.google.protobuf.CodedInputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static tech.ydb.proto.topic.YdbTopic.StreamReadMessage.FromServer parseFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry);
}
@java.lang.Override
public Builder newBuilderForType() { return newBuilder(); }
public static Builder newBuilder() {
return DEFAULT_INSTANCE.toBuilder();
}
public static Builder newBuilder(tech.ydb.proto.topic.YdbTopic.StreamReadMessage.FromServer prototype) {
return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
}
@java.lang.Override
public Builder toBuilder() {
return this == DEFAULT_INSTANCE
? new Builder() : new Builder().mergeFrom(this);
}
@java.lang.Override
protected Builder newBuilderForType(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
Builder builder = new Builder(parent);
return builder;
}
/**
*
* Server-client message for read session. Contains one of:
* InitResponse - handshake response from server.
* ReadResponse - portion of data.
* CommitOffsetResponse - acknowledgment for commit.
* PartitionSessionStatusResponse - server response with partition session status.
* UpdateTokenResponse - acknowledgment of token update.
*
* StartPartitionSessionRequest - command from server to create a partition session.
* StopPartitionSessionRequest - command from server to destroy a partition session.
* UpdatePartitionSession - command from server to update a partition session.
*
*
* Protobuf type {@code Ydb.Topic.StreamReadMessage.FromServer}
*/
public static final class Builder extends
com.google.protobuf.GeneratedMessageV3.Builder implements
// @@protoc_insertion_point(builder_implements:Ydb.Topic.StreamReadMessage.FromServer)
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.FromServerOrBuilder {
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_StreamReadMessage_FromServer_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_StreamReadMessage_FromServer_fieldAccessorTable
.ensureFieldAccessorsInitialized(
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.FromServer.class, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.FromServer.Builder.class);
}
// Construct using tech.ydb.proto.topic.YdbTopic.StreamReadMessage.FromServer.newBuilder()
private Builder() {
}
private Builder(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
super(parent);
}
@java.lang.Override
public Builder clear() {
super.clear();
bitField0_ = 0;
status_ = 0;
if (issuesBuilder_ == null) {
issues_ = java.util.Collections.emptyList();
} else {
issues_ = null;
issuesBuilder_.clear();
}
bitField0_ = (bitField0_ & ~0x00000002);
if (initResponseBuilder_ != null) {
initResponseBuilder_.clear();
}
if (readResponseBuilder_ != null) {
readResponseBuilder_.clear();
}
if (commitOffsetResponseBuilder_ != null) {
commitOffsetResponseBuilder_.clear();
}
if (partitionSessionStatusResponseBuilder_ != null) {
partitionSessionStatusResponseBuilder_.clear();
}
if (updateTokenResponseBuilder_ != null) {
updateTokenResponseBuilder_.clear();
}
if (startPartitionSessionRequestBuilder_ != null) {
startPartitionSessionRequestBuilder_.clear();
}
if (stopPartitionSessionRequestBuilder_ != null) {
stopPartitionSessionRequestBuilder_.clear();
}
if (updatePartitionSessionBuilder_ != null) {
updatePartitionSessionBuilder_.clear();
}
serverMessageCase_ = 0;
serverMessage_ = null;
return this;
}
@java.lang.Override
public com.google.protobuf.Descriptors.Descriptor
getDescriptorForType() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_StreamReadMessage_FromServer_descriptor;
}
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamReadMessage.FromServer getDefaultInstanceForType() {
return tech.ydb.proto.topic.YdbTopic.StreamReadMessage.FromServer.getDefaultInstance();
}
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamReadMessage.FromServer build() {
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.FromServer result = buildPartial();
if (!result.isInitialized()) {
throw newUninitializedMessageException(result);
}
return result;
}
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamReadMessage.FromServer buildPartial() {
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.FromServer result = new tech.ydb.proto.topic.YdbTopic.StreamReadMessage.FromServer(this);
buildPartialRepeatedFields(result);
if (bitField0_ != 0) { buildPartial0(result); }
buildPartialOneofs(result);
onBuilt();
return result;
}
private void buildPartialRepeatedFields(tech.ydb.proto.topic.YdbTopic.StreamReadMessage.FromServer result) {
if (issuesBuilder_ == null) {
if (((bitField0_ & 0x00000002) != 0)) {
issues_ = java.util.Collections.unmodifiableList(issues_);
bitField0_ = (bitField0_ & ~0x00000002);
}
result.issues_ = issues_;
} else {
result.issues_ = issuesBuilder_.build();
}
}
private void buildPartial0(tech.ydb.proto.topic.YdbTopic.StreamReadMessage.FromServer result) {
int from_bitField0_ = bitField0_;
if (((from_bitField0_ & 0x00000001) != 0)) {
result.status_ = status_;
}
}
private void buildPartialOneofs(tech.ydb.proto.topic.YdbTopic.StreamReadMessage.FromServer result) {
result.serverMessageCase_ = serverMessageCase_;
result.serverMessage_ = this.serverMessage_;
if (serverMessageCase_ == 3 &&
initResponseBuilder_ != null) {
result.serverMessage_ = initResponseBuilder_.build();
}
if (serverMessageCase_ == 4 &&
readResponseBuilder_ != null) {
result.serverMessage_ = readResponseBuilder_.build();
}
if (serverMessageCase_ == 5 &&
commitOffsetResponseBuilder_ != null) {
result.serverMessage_ = commitOffsetResponseBuilder_.build();
}
if (serverMessageCase_ == 6 &&
partitionSessionStatusResponseBuilder_ != null) {
result.serverMessage_ = partitionSessionStatusResponseBuilder_.build();
}
if (serverMessageCase_ == 7 &&
updateTokenResponseBuilder_ != null) {
result.serverMessage_ = updateTokenResponseBuilder_.build();
}
if (serverMessageCase_ == 8 &&
startPartitionSessionRequestBuilder_ != null) {
result.serverMessage_ = startPartitionSessionRequestBuilder_.build();
}
if (serverMessageCase_ == 9 &&
stopPartitionSessionRequestBuilder_ != null) {
result.serverMessage_ = stopPartitionSessionRequestBuilder_.build();
}
if (serverMessageCase_ == 10 &&
updatePartitionSessionBuilder_ != null) {
result.serverMessage_ = updatePartitionSessionBuilder_.build();
}
}
@java.lang.Override
public Builder clone() {
return super.clone();
}
@java.lang.Override
public Builder setField(
com.google.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) {
return super.setField(field, value);
}
@java.lang.Override
public Builder clearField(
com.google.protobuf.Descriptors.FieldDescriptor field) {
return super.clearField(field);
}
@java.lang.Override
public Builder clearOneof(
com.google.protobuf.Descriptors.OneofDescriptor oneof) {
return super.clearOneof(oneof);
}
@java.lang.Override
public Builder setRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
int index, java.lang.Object value) {
return super.setRepeatedField(field, index, value);
}
@java.lang.Override
public Builder addRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) {
return super.addRepeatedField(field, value);
}
@java.lang.Override
public Builder mergeFrom(com.google.protobuf.Message other) {
if (other instanceof tech.ydb.proto.topic.YdbTopic.StreamReadMessage.FromServer) {
return mergeFrom((tech.ydb.proto.topic.YdbTopic.StreamReadMessage.FromServer)other);
} else {
super.mergeFrom(other);
return this;
}
}
public Builder mergeFrom(tech.ydb.proto.topic.YdbTopic.StreamReadMessage.FromServer other) {
if (other == tech.ydb.proto.topic.YdbTopic.StreamReadMessage.FromServer.getDefaultInstance()) return this;
if (other.status_ != 0) {
setStatusValue(other.getStatusValue());
}
if (issuesBuilder_ == null) {
if (!other.issues_.isEmpty()) {
if (issues_.isEmpty()) {
issues_ = other.issues_;
bitField0_ = (bitField0_ & ~0x00000002);
} else {
ensureIssuesIsMutable();
issues_.addAll(other.issues_);
}
onChanged();
}
} else {
if (!other.issues_.isEmpty()) {
if (issuesBuilder_.isEmpty()) {
issuesBuilder_.dispose();
issuesBuilder_ = null;
issues_ = other.issues_;
bitField0_ = (bitField0_ & ~0x00000002);
issuesBuilder_ =
com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders ?
getIssuesFieldBuilder() : null;
} else {
issuesBuilder_.addAllMessages(other.issues_);
}
}
}
switch (other.getServerMessageCase()) {
case INIT_RESPONSE: {
mergeInitResponse(other.getInitResponse());
break;
}
case READ_RESPONSE: {
mergeReadResponse(other.getReadResponse());
break;
}
case COMMIT_OFFSET_RESPONSE: {
mergeCommitOffsetResponse(other.getCommitOffsetResponse());
break;
}
case PARTITION_SESSION_STATUS_RESPONSE: {
mergePartitionSessionStatusResponse(other.getPartitionSessionStatusResponse());
break;
}
case UPDATE_TOKEN_RESPONSE: {
mergeUpdateTokenResponse(other.getUpdateTokenResponse());
break;
}
case START_PARTITION_SESSION_REQUEST: {
mergeStartPartitionSessionRequest(other.getStartPartitionSessionRequest());
break;
}
case STOP_PARTITION_SESSION_REQUEST: {
mergeStopPartitionSessionRequest(other.getStopPartitionSessionRequest());
break;
}
case UPDATE_PARTITION_SESSION: {
mergeUpdatePartitionSession(other.getUpdatePartitionSession());
break;
}
case SERVERMESSAGE_NOT_SET: {
break;
}
}
this.mergeUnknownFields(other.getUnknownFields());
onChanged();
return this;
}
@java.lang.Override
public final boolean isInitialized() {
return true;
}
@java.lang.Override
public Builder mergeFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
if (extensionRegistry == null) {
throw new java.lang.NullPointerException();
}
try {
boolean done = false;
while (!done) {
int tag = input.readTag();
switch (tag) {
case 0:
done = true;
break;
case 8: {
status_ = input.readEnum();
bitField0_ |= 0x00000001;
break;
} // case 8
case 18: {
tech.ydb.proto.YdbIssueMessage.IssueMessage m =
input.readMessage(
tech.ydb.proto.YdbIssueMessage.IssueMessage.parser(),
extensionRegistry);
if (issuesBuilder_ == null) {
ensureIssuesIsMutable();
issues_.add(m);
} else {
issuesBuilder_.addMessage(m);
}
break;
} // case 18
case 26: {
input.readMessage(
getInitResponseFieldBuilder().getBuilder(),
extensionRegistry);
serverMessageCase_ = 3;
break;
} // case 26
case 34: {
input.readMessage(
getReadResponseFieldBuilder().getBuilder(),
extensionRegistry);
serverMessageCase_ = 4;
break;
} // case 34
case 42: {
input.readMessage(
getCommitOffsetResponseFieldBuilder().getBuilder(),
extensionRegistry);
serverMessageCase_ = 5;
break;
} // case 42
case 50: {
input.readMessage(
getPartitionSessionStatusResponseFieldBuilder().getBuilder(),
extensionRegistry);
serverMessageCase_ = 6;
break;
} // case 50
case 58: {
input.readMessage(
getUpdateTokenResponseFieldBuilder().getBuilder(),
extensionRegistry);
serverMessageCase_ = 7;
break;
} // case 58
case 66: {
input.readMessage(
getStartPartitionSessionRequestFieldBuilder().getBuilder(),
extensionRegistry);
serverMessageCase_ = 8;
break;
} // case 66
case 74: {
input.readMessage(
getStopPartitionSessionRequestFieldBuilder().getBuilder(),
extensionRegistry);
serverMessageCase_ = 9;
break;
} // case 74
case 82: {
input.readMessage(
getUpdatePartitionSessionFieldBuilder().getBuilder(),
extensionRegistry);
serverMessageCase_ = 10;
break;
} // case 82
default: {
if (!super.parseUnknownField(input, extensionRegistry, tag)) {
done = true; // was an endgroup tag
}
break;
} // default:
} // switch (tag)
} // while (!done)
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.unwrapIOException();
} finally {
onChanged();
} // finally
return this;
}
private int serverMessageCase_ = 0;
private java.lang.Object serverMessage_;
public ServerMessageCase
getServerMessageCase() {
return ServerMessageCase.forNumber(
serverMessageCase_);
}
public Builder clearServerMessage() {
serverMessageCase_ = 0;
serverMessage_ = null;
onChanged();
return this;
}
private int bitField0_;
private int status_ = 0;
/**
*
* Server status of response.
*
*
* .Ydb.StatusIds.StatusCode status = 1;
* @return The enum numeric value on the wire for status.
*/
@java.lang.Override public int getStatusValue() {
return status_;
}
/**
*
* Server status of response.
*
*
* .Ydb.StatusIds.StatusCode status = 1;
* @param value The enum numeric value on the wire for status to set.
* @return This builder for chaining.
*/
public Builder setStatusValue(int value) {
status_ = value;
bitField0_ |= 0x00000001;
onChanged();
return this;
}
/**
*
* Server status of response.
*
*
* .Ydb.StatusIds.StatusCode status = 1;
* @return The status.
*/
@java.lang.Override
public tech.ydb.proto.StatusCodesProtos.StatusIds.StatusCode getStatus() {
tech.ydb.proto.StatusCodesProtos.StatusIds.StatusCode result = tech.ydb.proto.StatusCodesProtos.StatusIds.StatusCode.forNumber(status_);
return result == null ? tech.ydb.proto.StatusCodesProtos.StatusIds.StatusCode.UNRECOGNIZED : result;
}
/**
*
* Server status of response.
*
*
* .Ydb.StatusIds.StatusCode status = 1;
* @param value The status to set.
* @return This builder for chaining.
*/
public Builder setStatus(tech.ydb.proto.StatusCodesProtos.StatusIds.StatusCode value) {
if (value == null) {
throw new NullPointerException();
}
bitField0_ |= 0x00000001;
status_ = value.getNumber();
onChanged();
return this;
}
/**
*
* Server status of response.
*
*
* .Ydb.StatusIds.StatusCode status = 1;
* @return This builder for chaining.
*/
public Builder clearStatus() {
bitField0_ = (bitField0_ & ~0x00000001);
status_ = 0;
onChanged();
return this;
}
private java.util.List issues_ =
java.util.Collections.emptyList();
private void ensureIssuesIsMutable() {
if (!((bitField0_ & 0x00000002) != 0)) {
issues_ = new java.util.ArrayList(issues_);
bitField0_ |= 0x00000002;
}
}
private com.google.protobuf.RepeatedFieldBuilderV3<
tech.ydb.proto.YdbIssueMessage.IssueMessage, tech.ydb.proto.YdbIssueMessage.IssueMessage.Builder, tech.ydb.proto.YdbIssueMessage.IssueMessageOrBuilder> issuesBuilder_;
/**
*
* Issues if any.
*
*
* repeated .Ydb.Issue.IssueMessage issues = 2;
*/
public java.util.List getIssuesList() {
if (issuesBuilder_ == null) {
return java.util.Collections.unmodifiableList(issues_);
} else {
return issuesBuilder_.getMessageList();
}
}
/**
*
* Issues if any.
*
*
* repeated .Ydb.Issue.IssueMessage issues = 2;
*/
public int getIssuesCount() {
if (issuesBuilder_ == null) {
return issues_.size();
} else {
return issuesBuilder_.getCount();
}
}
/**
*
* Issues if any.
*
*
* repeated .Ydb.Issue.IssueMessage issues = 2;
*/
public tech.ydb.proto.YdbIssueMessage.IssueMessage getIssues(int index) {
if (issuesBuilder_ == null) {
return issues_.get(index);
} else {
return issuesBuilder_.getMessage(index);
}
}
/**
*
* Issues if any.
*
*
* repeated .Ydb.Issue.IssueMessage issues = 2;
*/
public Builder setIssues(
int index, tech.ydb.proto.YdbIssueMessage.IssueMessage value) {
if (issuesBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
ensureIssuesIsMutable();
issues_.set(index, value);
onChanged();
} else {
issuesBuilder_.setMessage(index, value);
}
return this;
}
/**
*
* Issues if any.
*
*
* repeated .Ydb.Issue.IssueMessage issues = 2;
*/
public Builder setIssues(
int index, tech.ydb.proto.YdbIssueMessage.IssueMessage.Builder builderForValue) {
if (issuesBuilder_ == null) {
ensureIssuesIsMutable();
issues_.set(index, builderForValue.build());
onChanged();
} else {
issuesBuilder_.setMessage(index, builderForValue.build());
}
return this;
}
/**
*
* Issues if any.
*
*
* repeated .Ydb.Issue.IssueMessage issues = 2;
*/
public Builder addIssues(tech.ydb.proto.YdbIssueMessage.IssueMessage value) {
if (issuesBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
ensureIssuesIsMutable();
issues_.add(value);
onChanged();
} else {
issuesBuilder_.addMessage(value);
}
return this;
}
/**
*
* Issues if any.
*
*
* repeated .Ydb.Issue.IssueMessage issues = 2;
*/
public Builder addIssues(
int index, tech.ydb.proto.YdbIssueMessage.IssueMessage value) {
if (issuesBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
ensureIssuesIsMutable();
issues_.add(index, value);
onChanged();
} else {
issuesBuilder_.addMessage(index, value);
}
return this;
}
/**
*
* Issues if any.
*
*
* repeated .Ydb.Issue.IssueMessage issues = 2;
*/
public Builder addIssues(
tech.ydb.proto.YdbIssueMessage.IssueMessage.Builder builderForValue) {
if (issuesBuilder_ == null) {
ensureIssuesIsMutable();
issues_.add(builderForValue.build());
onChanged();
} else {
issuesBuilder_.addMessage(builderForValue.build());
}
return this;
}
/**
*
* Issues if any.
*
*
* repeated .Ydb.Issue.IssueMessage issues = 2;
*/
public Builder addIssues(
int index, tech.ydb.proto.YdbIssueMessage.IssueMessage.Builder builderForValue) {
if (issuesBuilder_ == null) {
ensureIssuesIsMutable();
issues_.add(index, builderForValue.build());
onChanged();
} else {
issuesBuilder_.addMessage(index, builderForValue.build());
}
return this;
}
/**
*
* Issues if any.
*
*
* repeated .Ydb.Issue.IssueMessage issues = 2;
*/
public Builder addAllIssues(
java.lang.Iterable extends tech.ydb.proto.YdbIssueMessage.IssueMessage> values) {
if (issuesBuilder_ == null) {
ensureIssuesIsMutable();
com.google.protobuf.AbstractMessageLite.Builder.addAll(
values, issues_);
onChanged();
} else {
issuesBuilder_.addAllMessages(values);
}
return this;
}
/**
*
* Issues if any.
*
*
* repeated .Ydb.Issue.IssueMessage issues = 2;
*/
public Builder clearIssues() {
if (issuesBuilder_ == null) {
issues_ = java.util.Collections.emptyList();
bitField0_ = (bitField0_ & ~0x00000002);
onChanged();
} else {
issuesBuilder_.clear();
}
return this;
}
/**
*
* Issues if any.
*
*
* repeated .Ydb.Issue.IssueMessage issues = 2;
*/
public Builder removeIssues(int index) {
if (issuesBuilder_ == null) {
ensureIssuesIsMutable();
issues_.remove(index);
onChanged();
} else {
issuesBuilder_.remove(index);
}
return this;
}
/**
*
* Issues if any.
*
*
* repeated .Ydb.Issue.IssueMessage issues = 2;
*/
public tech.ydb.proto.YdbIssueMessage.IssueMessage.Builder getIssuesBuilder(
int index) {
return getIssuesFieldBuilder().getBuilder(index);
}
/**
*
* Issues if any.
*
*
* repeated .Ydb.Issue.IssueMessage issues = 2;
*/
public tech.ydb.proto.YdbIssueMessage.IssueMessageOrBuilder getIssuesOrBuilder(
int index) {
if (issuesBuilder_ == null) {
return issues_.get(index); } else {
return issuesBuilder_.getMessageOrBuilder(index);
}
}
/**
*
* Issues if any.
*
*
* repeated .Ydb.Issue.IssueMessage issues = 2;
*/
public java.util.List extends tech.ydb.proto.YdbIssueMessage.IssueMessageOrBuilder>
getIssuesOrBuilderList() {
if (issuesBuilder_ != null) {
return issuesBuilder_.getMessageOrBuilderList();
} else {
return java.util.Collections.unmodifiableList(issues_);
}
}
/**
*
* Issues if any.
*
*
* repeated .Ydb.Issue.IssueMessage issues = 2;
*/
public tech.ydb.proto.YdbIssueMessage.IssueMessage.Builder addIssuesBuilder() {
return getIssuesFieldBuilder().addBuilder(
tech.ydb.proto.YdbIssueMessage.IssueMessage.getDefaultInstance());
}
/**
*
* Issues if any.
*
*
* repeated .Ydb.Issue.IssueMessage issues = 2;
*/
public tech.ydb.proto.YdbIssueMessage.IssueMessage.Builder addIssuesBuilder(
int index) {
return getIssuesFieldBuilder().addBuilder(
index, tech.ydb.proto.YdbIssueMessage.IssueMessage.getDefaultInstance());
}
/**
*
* Issues if any.
*
*
* repeated .Ydb.Issue.IssueMessage issues = 2;
*/
public java.util.List
getIssuesBuilderList() {
return getIssuesFieldBuilder().getBuilderList();
}
private com.google.protobuf.RepeatedFieldBuilderV3<
tech.ydb.proto.YdbIssueMessage.IssueMessage, tech.ydb.proto.YdbIssueMessage.IssueMessage.Builder, tech.ydb.proto.YdbIssueMessage.IssueMessageOrBuilder>
getIssuesFieldBuilder() {
if (issuesBuilder_ == null) {
issuesBuilder_ = new com.google.protobuf.RepeatedFieldBuilderV3<
tech.ydb.proto.YdbIssueMessage.IssueMessage, tech.ydb.proto.YdbIssueMessage.IssueMessage.Builder, tech.ydb.proto.YdbIssueMessage.IssueMessageOrBuilder>(
issues_,
((bitField0_ & 0x00000002) != 0),
getParentForChildren(),
isClean());
issues_ = null;
}
return issuesBuilder_;
}
private com.google.protobuf.SingleFieldBuilderV3<
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitResponse, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitResponse.Builder, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitResponseOrBuilder> initResponseBuilder_;
/**
*
* Responses to respective client requests.
*
*
* .Ydb.Topic.StreamReadMessage.InitResponse init_response = 3;
* @return Whether the initResponse field is set.
*/
@java.lang.Override
public boolean hasInitResponse() {
return serverMessageCase_ == 3;
}
/**
*
* Responses to respective client requests.
*
*
* .Ydb.Topic.StreamReadMessage.InitResponse init_response = 3;
* @return The initResponse.
*/
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitResponse getInitResponse() {
if (initResponseBuilder_ == null) {
if (serverMessageCase_ == 3) {
return (tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitResponse) serverMessage_;
}
return tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitResponse.getDefaultInstance();
} else {
if (serverMessageCase_ == 3) {
return initResponseBuilder_.getMessage();
}
return tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitResponse.getDefaultInstance();
}
}
/**
*
* Responses to respective client requests.
*
*
* .Ydb.Topic.StreamReadMessage.InitResponse init_response = 3;
*/
public Builder setInitResponse(tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitResponse value) {
if (initResponseBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
serverMessage_ = value;
onChanged();
} else {
initResponseBuilder_.setMessage(value);
}
serverMessageCase_ = 3;
return this;
}
/**
*
* Responses to respective client requests.
*
*
* .Ydb.Topic.StreamReadMessage.InitResponse init_response = 3;
*/
public Builder setInitResponse(
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitResponse.Builder builderForValue) {
if (initResponseBuilder_ == null) {
serverMessage_ = builderForValue.build();
onChanged();
} else {
initResponseBuilder_.setMessage(builderForValue.build());
}
serverMessageCase_ = 3;
return this;
}
/**
*
* Responses to respective client requests.
*
*
* .Ydb.Topic.StreamReadMessage.InitResponse init_response = 3;
*/
public Builder mergeInitResponse(tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitResponse value) {
if (initResponseBuilder_ == null) {
if (serverMessageCase_ == 3 &&
serverMessage_ != tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitResponse.getDefaultInstance()) {
serverMessage_ = tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitResponse.newBuilder((tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitResponse) serverMessage_)
.mergeFrom(value).buildPartial();
} else {
serverMessage_ = value;
}
onChanged();
} else {
if (serverMessageCase_ == 3) {
initResponseBuilder_.mergeFrom(value);
} else {
initResponseBuilder_.setMessage(value);
}
}
serverMessageCase_ = 3;
return this;
}
/**
*
* Responses to respective client requests.
*
*
* .Ydb.Topic.StreamReadMessage.InitResponse init_response = 3;
*/
public Builder clearInitResponse() {
if (initResponseBuilder_ == null) {
if (serverMessageCase_ == 3) {
serverMessageCase_ = 0;
serverMessage_ = null;
onChanged();
}
} else {
if (serverMessageCase_ == 3) {
serverMessageCase_ = 0;
serverMessage_ = null;
}
initResponseBuilder_.clear();
}
return this;
}
/**
*
* Responses to respective client requests.
*
*
* .Ydb.Topic.StreamReadMessage.InitResponse init_response = 3;
*/
public tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitResponse.Builder getInitResponseBuilder() {
return getInitResponseFieldBuilder().getBuilder();
}
/**
*
* Responses to respective client requests.
*
*
* .Ydb.Topic.StreamReadMessage.InitResponse init_response = 3;
*/
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitResponseOrBuilder getInitResponseOrBuilder() {
if ((serverMessageCase_ == 3) && (initResponseBuilder_ != null)) {
return initResponseBuilder_.getMessageOrBuilder();
} else {
if (serverMessageCase_ == 3) {
return (tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitResponse) serverMessage_;
}
return tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitResponse.getDefaultInstance();
}
}
/**
*
* Responses to respective client requests.
*
*
* .Ydb.Topic.StreamReadMessage.InitResponse init_response = 3;
*/
private com.google.protobuf.SingleFieldBuilderV3<
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitResponse, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitResponse.Builder, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitResponseOrBuilder>
getInitResponseFieldBuilder() {
if (initResponseBuilder_ == null) {
if (!(serverMessageCase_ == 3)) {
serverMessage_ = tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitResponse.getDefaultInstance();
}
initResponseBuilder_ = new com.google.protobuf.SingleFieldBuilderV3<
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitResponse, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitResponse.Builder, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitResponseOrBuilder>(
(tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitResponse) serverMessage_,
getParentForChildren(),
isClean());
serverMessage_ = null;
}
serverMessageCase_ = 3;
onChanged();
return initResponseBuilder_;
}
private com.google.protobuf.SingleFieldBuilderV3<
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.Builder, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponseOrBuilder> readResponseBuilder_;
/**
* .Ydb.Topic.StreamReadMessage.ReadResponse read_response = 4;
* @return Whether the readResponse field is set.
*/
@java.lang.Override
public boolean hasReadResponse() {
return serverMessageCase_ == 4;
}
/**
* .Ydb.Topic.StreamReadMessage.ReadResponse read_response = 4;
* @return The readResponse.
*/
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse getReadResponse() {
if (readResponseBuilder_ == null) {
if (serverMessageCase_ == 4) {
return (tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse) serverMessage_;
}
return tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.getDefaultInstance();
} else {
if (serverMessageCase_ == 4) {
return readResponseBuilder_.getMessage();
}
return tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.getDefaultInstance();
}
}
/**
* .Ydb.Topic.StreamReadMessage.ReadResponse read_response = 4;
*/
public Builder setReadResponse(tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse value) {
if (readResponseBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
serverMessage_ = value;
onChanged();
} else {
readResponseBuilder_.setMessage(value);
}
serverMessageCase_ = 4;
return this;
}
/**
* .Ydb.Topic.StreamReadMessage.ReadResponse read_response = 4;
*/
public Builder setReadResponse(
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.Builder builderForValue) {
if (readResponseBuilder_ == null) {
serverMessage_ = builderForValue.build();
onChanged();
} else {
readResponseBuilder_.setMessage(builderForValue.build());
}
serverMessageCase_ = 4;
return this;
}
/**
* .Ydb.Topic.StreamReadMessage.ReadResponse read_response = 4;
*/
public Builder mergeReadResponse(tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse value) {
if (readResponseBuilder_ == null) {
if (serverMessageCase_ == 4 &&
serverMessage_ != tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.getDefaultInstance()) {
serverMessage_ = tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.newBuilder((tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse) serverMessage_)
.mergeFrom(value).buildPartial();
} else {
serverMessage_ = value;
}
onChanged();
} else {
if (serverMessageCase_ == 4) {
readResponseBuilder_.mergeFrom(value);
} else {
readResponseBuilder_.setMessage(value);
}
}
serverMessageCase_ = 4;
return this;
}
/**
* .Ydb.Topic.StreamReadMessage.ReadResponse read_response = 4;
*/
public Builder clearReadResponse() {
if (readResponseBuilder_ == null) {
if (serverMessageCase_ == 4) {
serverMessageCase_ = 0;
serverMessage_ = null;
onChanged();
}
} else {
if (serverMessageCase_ == 4) {
serverMessageCase_ = 0;
serverMessage_ = null;
}
readResponseBuilder_.clear();
}
return this;
}
/**
* .Ydb.Topic.StreamReadMessage.ReadResponse read_response = 4;
*/
public tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.Builder getReadResponseBuilder() {
return getReadResponseFieldBuilder().getBuilder();
}
/**
* .Ydb.Topic.StreamReadMessage.ReadResponse read_response = 4;
*/
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponseOrBuilder getReadResponseOrBuilder() {
if ((serverMessageCase_ == 4) && (readResponseBuilder_ != null)) {
return readResponseBuilder_.getMessageOrBuilder();
} else {
if (serverMessageCase_ == 4) {
return (tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse) serverMessage_;
}
return tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.getDefaultInstance();
}
}
/**
* .Ydb.Topic.StreamReadMessage.ReadResponse read_response = 4;
*/
private com.google.protobuf.SingleFieldBuilderV3<
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.Builder, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponseOrBuilder>
getReadResponseFieldBuilder() {
if (readResponseBuilder_ == null) {
if (!(serverMessageCase_ == 4)) {
serverMessage_ = tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.getDefaultInstance();
}
readResponseBuilder_ = new com.google.protobuf.SingleFieldBuilderV3<
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.Builder, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponseOrBuilder>(
(tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse) serverMessage_,
getParentForChildren(),
isClean());
serverMessage_ = null;
}
serverMessageCase_ = 4;
onChanged();
return readResponseBuilder_;
}
private com.google.protobuf.SingleFieldBuilderV3<
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.CommitOffsetResponse, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.CommitOffsetResponse.Builder, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.CommitOffsetResponseOrBuilder> commitOffsetResponseBuilder_;
/**
* .Ydb.Topic.StreamReadMessage.CommitOffsetResponse commit_offset_response = 5;
* @return Whether the commitOffsetResponse field is set.
*/
@java.lang.Override
public boolean hasCommitOffsetResponse() {
return serverMessageCase_ == 5;
}
/**
* .Ydb.Topic.StreamReadMessage.CommitOffsetResponse commit_offset_response = 5;
* @return The commitOffsetResponse.
*/
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamReadMessage.CommitOffsetResponse getCommitOffsetResponse() {
if (commitOffsetResponseBuilder_ == null) {
if (serverMessageCase_ == 5) {
return (tech.ydb.proto.topic.YdbTopic.StreamReadMessage.CommitOffsetResponse) serverMessage_;
}
return tech.ydb.proto.topic.YdbTopic.StreamReadMessage.CommitOffsetResponse.getDefaultInstance();
} else {
if (serverMessageCase_ == 5) {
return commitOffsetResponseBuilder_.getMessage();
}
return tech.ydb.proto.topic.YdbTopic.StreamReadMessage.CommitOffsetResponse.getDefaultInstance();
}
}
/**
* .Ydb.Topic.StreamReadMessage.CommitOffsetResponse commit_offset_response = 5;
*/
public Builder setCommitOffsetResponse(tech.ydb.proto.topic.YdbTopic.StreamReadMessage.CommitOffsetResponse value) {
if (commitOffsetResponseBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
serverMessage_ = value;
onChanged();
} else {
commitOffsetResponseBuilder_.setMessage(value);
}
serverMessageCase_ = 5;
return this;
}
/**
* .Ydb.Topic.StreamReadMessage.CommitOffsetResponse commit_offset_response = 5;
*/
public Builder setCommitOffsetResponse(
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.CommitOffsetResponse.Builder builderForValue) {
if (commitOffsetResponseBuilder_ == null) {
serverMessage_ = builderForValue.build();
onChanged();
} else {
commitOffsetResponseBuilder_.setMessage(builderForValue.build());
}
serverMessageCase_ = 5;
return this;
}
/**
* .Ydb.Topic.StreamReadMessage.CommitOffsetResponse commit_offset_response = 5;
*/
public Builder mergeCommitOffsetResponse(tech.ydb.proto.topic.YdbTopic.StreamReadMessage.CommitOffsetResponse value) {
if (commitOffsetResponseBuilder_ == null) {
if (serverMessageCase_ == 5 &&
serverMessage_ != tech.ydb.proto.topic.YdbTopic.StreamReadMessage.CommitOffsetResponse.getDefaultInstance()) {
serverMessage_ = tech.ydb.proto.topic.YdbTopic.StreamReadMessage.CommitOffsetResponse.newBuilder((tech.ydb.proto.topic.YdbTopic.StreamReadMessage.CommitOffsetResponse) serverMessage_)
.mergeFrom(value).buildPartial();
} else {
serverMessage_ = value;
}
onChanged();
} else {
if (serverMessageCase_ == 5) {
commitOffsetResponseBuilder_.mergeFrom(value);
} else {
commitOffsetResponseBuilder_.setMessage(value);
}
}
serverMessageCase_ = 5;
return this;
}
/**
* .Ydb.Topic.StreamReadMessage.CommitOffsetResponse commit_offset_response = 5;
*/
public Builder clearCommitOffsetResponse() {
if (commitOffsetResponseBuilder_ == null) {
if (serverMessageCase_ == 5) {
serverMessageCase_ = 0;
serverMessage_ = null;
onChanged();
}
} else {
if (serverMessageCase_ == 5) {
serverMessageCase_ = 0;
serverMessage_ = null;
}
commitOffsetResponseBuilder_.clear();
}
return this;
}
/**
* .Ydb.Topic.StreamReadMessage.CommitOffsetResponse commit_offset_response = 5;
*/
public tech.ydb.proto.topic.YdbTopic.StreamReadMessage.CommitOffsetResponse.Builder getCommitOffsetResponseBuilder() {
return getCommitOffsetResponseFieldBuilder().getBuilder();
}
/**
* .Ydb.Topic.StreamReadMessage.CommitOffsetResponse commit_offset_response = 5;
*/
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamReadMessage.CommitOffsetResponseOrBuilder getCommitOffsetResponseOrBuilder() {
if ((serverMessageCase_ == 5) && (commitOffsetResponseBuilder_ != null)) {
return commitOffsetResponseBuilder_.getMessageOrBuilder();
} else {
if (serverMessageCase_ == 5) {
return (tech.ydb.proto.topic.YdbTopic.StreamReadMessage.CommitOffsetResponse) serverMessage_;
}
return tech.ydb.proto.topic.YdbTopic.StreamReadMessage.CommitOffsetResponse.getDefaultInstance();
}
}
/**
* .Ydb.Topic.StreamReadMessage.CommitOffsetResponse commit_offset_response = 5;
*/
private com.google.protobuf.SingleFieldBuilderV3<
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.CommitOffsetResponse, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.CommitOffsetResponse.Builder, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.CommitOffsetResponseOrBuilder>
getCommitOffsetResponseFieldBuilder() {
if (commitOffsetResponseBuilder_ == null) {
if (!(serverMessageCase_ == 5)) {
serverMessage_ = tech.ydb.proto.topic.YdbTopic.StreamReadMessage.CommitOffsetResponse.getDefaultInstance();
}
commitOffsetResponseBuilder_ = new com.google.protobuf.SingleFieldBuilderV3<
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.CommitOffsetResponse, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.CommitOffsetResponse.Builder, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.CommitOffsetResponseOrBuilder>(
(tech.ydb.proto.topic.YdbTopic.StreamReadMessage.CommitOffsetResponse) serverMessage_,
getParentForChildren(),
isClean());
serverMessage_ = null;
}
serverMessageCase_ = 5;
onChanged();
return commitOffsetResponseBuilder_;
}
private com.google.protobuf.SingleFieldBuilderV3<
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.PartitionSessionStatusResponse, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.PartitionSessionStatusResponse.Builder, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.PartitionSessionStatusResponseOrBuilder> partitionSessionStatusResponseBuilder_;
/**
* .Ydb.Topic.StreamReadMessage.PartitionSessionStatusResponse partition_session_status_response = 6;
* @return Whether the partitionSessionStatusResponse field is set.
*/
@java.lang.Override
public boolean hasPartitionSessionStatusResponse() {
return serverMessageCase_ == 6;
}
/**
* .Ydb.Topic.StreamReadMessage.PartitionSessionStatusResponse partition_session_status_response = 6;
* @return The partitionSessionStatusResponse.
*/
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamReadMessage.PartitionSessionStatusResponse getPartitionSessionStatusResponse() {
if (partitionSessionStatusResponseBuilder_ == null) {
if (serverMessageCase_ == 6) {
return (tech.ydb.proto.topic.YdbTopic.StreamReadMessage.PartitionSessionStatusResponse) serverMessage_;
}
return tech.ydb.proto.topic.YdbTopic.StreamReadMessage.PartitionSessionStatusResponse.getDefaultInstance();
} else {
if (serverMessageCase_ == 6) {
return partitionSessionStatusResponseBuilder_.getMessage();
}
return tech.ydb.proto.topic.YdbTopic.StreamReadMessage.PartitionSessionStatusResponse.getDefaultInstance();
}
}
/**
* .Ydb.Topic.StreamReadMessage.PartitionSessionStatusResponse partition_session_status_response = 6;
*/
public Builder setPartitionSessionStatusResponse(tech.ydb.proto.topic.YdbTopic.StreamReadMessage.PartitionSessionStatusResponse value) {
if (partitionSessionStatusResponseBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
serverMessage_ = value;
onChanged();
} else {
partitionSessionStatusResponseBuilder_.setMessage(value);
}
serverMessageCase_ = 6;
return this;
}
/**
* .Ydb.Topic.StreamReadMessage.PartitionSessionStatusResponse partition_session_status_response = 6;
*/
public Builder setPartitionSessionStatusResponse(
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.PartitionSessionStatusResponse.Builder builderForValue) {
if (partitionSessionStatusResponseBuilder_ == null) {
serverMessage_ = builderForValue.build();
onChanged();
} else {
partitionSessionStatusResponseBuilder_.setMessage(builderForValue.build());
}
serverMessageCase_ = 6;
return this;
}
/**
* .Ydb.Topic.StreamReadMessage.PartitionSessionStatusResponse partition_session_status_response = 6;
*/
public Builder mergePartitionSessionStatusResponse(tech.ydb.proto.topic.YdbTopic.StreamReadMessage.PartitionSessionStatusResponse value) {
if (partitionSessionStatusResponseBuilder_ == null) {
if (serverMessageCase_ == 6 &&
serverMessage_ != tech.ydb.proto.topic.YdbTopic.StreamReadMessage.PartitionSessionStatusResponse.getDefaultInstance()) {
serverMessage_ = tech.ydb.proto.topic.YdbTopic.StreamReadMessage.PartitionSessionStatusResponse.newBuilder((tech.ydb.proto.topic.YdbTopic.StreamReadMessage.PartitionSessionStatusResponse) serverMessage_)
.mergeFrom(value).buildPartial();
} else {
serverMessage_ = value;
}
onChanged();
} else {
if (serverMessageCase_ == 6) {
partitionSessionStatusResponseBuilder_.mergeFrom(value);
} else {
partitionSessionStatusResponseBuilder_.setMessage(value);
}
}
serverMessageCase_ = 6;
return this;
}
/**
* .Ydb.Topic.StreamReadMessage.PartitionSessionStatusResponse partition_session_status_response = 6;
*/
public Builder clearPartitionSessionStatusResponse() {
if (partitionSessionStatusResponseBuilder_ == null) {
if (serverMessageCase_ == 6) {
serverMessageCase_ = 0;
serverMessage_ = null;
onChanged();
}
} else {
if (serverMessageCase_ == 6) {
serverMessageCase_ = 0;
serverMessage_ = null;
}
partitionSessionStatusResponseBuilder_.clear();
}
return this;
}
/**
* .Ydb.Topic.StreamReadMessage.PartitionSessionStatusResponse partition_session_status_response = 6;
*/
public tech.ydb.proto.topic.YdbTopic.StreamReadMessage.PartitionSessionStatusResponse.Builder getPartitionSessionStatusResponseBuilder() {
return getPartitionSessionStatusResponseFieldBuilder().getBuilder();
}
/**
* .Ydb.Topic.StreamReadMessage.PartitionSessionStatusResponse partition_session_status_response = 6;
*/
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamReadMessage.PartitionSessionStatusResponseOrBuilder getPartitionSessionStatusResponseOrBuilder() {
if ((serverMessageCase_ == 6) && (partitionSessionStatusResponseBuilder_ != null)) {
return partitionSessionStatusResponseBuilder_.getMessageOrBuilder();
} else {
if (serverMessageCase_ == 6) {
return (tech.ydb.proto.topic.YdbTopic.StreamReadMessage.PartitionSessionStatusResponse) serverMessage_;
}
return tech.ydb.proto.topic.YdbTopic.StreamReadMessage.PartitionSessionStatusResponse.getDefaultInstance();
}
}
/**
* .Ydb.Topic.StreamReadMessage.PartitionSessionStatusResponse partition_session_status_response = 6;
*/
private com.google.protobuf.SingleFieldBuilderV3<
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.PartitionSessionStatusResponse, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.PartitionSessionStatusResponse.Builder, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.PartitionSessionStatusResponseOrBuilder>
getPartitionSessionStatusResponseFieldBuilder() {
if (partitionSessionStatusResponseBuilder_ == null) {
if (!(serverMessageCase_ == 6)) {
serverMessage_ = tech.ydb.proto.topic.YdbTopic.StreamReadMessage.PartitionSessionStatusResponse.getDefaultInstance();
}
partitionSessionStatusResponseBuilder_ = new com.google.protobuf.SingleFieldBuilderV3<
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.PartitionSessionStatusResponse, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.PartitionSessionStatusResponse.Builder, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.PartitionSessionStatusResponseOrBuilder>(
(tech.ydb.proto.topic.YdbTopic.StreamReadMessage.PartitionSessionStatusResponse) serverMessage_,
getParentForChildren(),
isClean());
serverMessage_ = null;
}
serverMessageCase_ = 6;
onChanged();
return partitionSessionStatusResponseBuilder_;
}
private com.google.protobuf.SingleFieldBuilderV3<
tech.ydb.proto.topic.YdbTopic.UpdateTokenResponse, tech.ydb.proto.topic.YdbTopic.UpdateTokenResponse.Builder, tech.ydb.proto.topic.YdbTopic.UpdateTokenResponseOrBuilder> updateTokenResponseBuilder_;
/**
* .Ydb.Topic.UpdateTokenResponse update_token_response = 7;
* @return Whether the updateTokenResponse field is set.
*/
@java.lang.Override
public boolean hasUpdateTokenResponse() {
return serverMessageCase_ == 7;
}
/**
* .Ydb.Topic.UpdateTokenResponse update_token_response = 7;
* @return The updateTokenResponse.
*/
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.UpdateTokenResponse getUpdateTokenResponse() {
if (updateTokenResponseBuilder_ == null) {
if (serverMessageCase_ == 7) {
return (tech.ydb.proto.topic.YdbTopic.UpdateTokenResponse) serverMessage_;
}
return tech.ydb.proto.topic.YdbTopic.UpdateTokenResponse.getDefaultInstance();
} else {
if (serverMessageCase_ == 7) {
return updateTokenResponseBuilder_.getMessage();
}
return tech.ydb.proto.topic.YdbTopic.UpdateTokenResponse.getDefaultInstance();
}
}
/**
* .Ydb.Topic.UpdateTokenResponse update_token_response = 7;
*/
public Builder setUpdateTokenResponse(tech.ydb.proto.topic.YdbTopic.UpdateTokenResponse value) {
if (updateTokenResponseBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
serverMessage_ = value;
onChanged();
} else {
updateTokenResponseBuilder_.setMessage(value);
}
serverMessageCase_ = 7;
return this;
}
/**
* .Ydb.Topic.UpdateTokenResponse update_token_response = 7;
*/
public Builder setUpdateTokenResponse(
tech.ydb.proto.topic.YdbTopic.UpdateTokenResponse.Builder builderForValue) {
if (updateTokenResponseBuilder_ == null) {
serverMessage_ = builderForValue.build();
onChanged();
} else {
updateTokenResponseBuilder_.setMessage(builderForValue.build());
}
serverMessageCase_ = 7;
return this;
}
/**
* .Ydb.Topic.UpdateTokenResponse update_token_response = 7;
*/
public Builder mergeUpdateTokenResponse(tech.ydb.proto.topic.YdbTopic.UpdateTokenResponse value) {
if (updateTokenResponseBuilder_ == null) {
if (serverMessageCase_ == 7 &&
serverMessage_ != tech.ydb.proto.topic.YdbTopic.UpdateTokenResponse.getDefaultInstance()) {
serverMessage_ = tech.ydb.proto.topic.YdbTopic.UpdateTokenResponse.newBuilder((tech.ydb.proto.topic.YdbTopic.UpdateTokenResponse) serverMessage_)
.mergeFrom(value).buildPartial();
} else {
serverMessage_ = value;
}
onChanged();
} else {
if (serverMessageCase_ == 7) {
updateTokenResponseBuilder_.mergeFrom(value);
} else {
updateTokenResponseBuilder_.setMessage(value);
}
}
serverMessageCase_ = 7;
return this;
}
/**
* .Ydb.Topic.UpdateTokenResponse update_token_response = 7;
*/
public Builder clearUpdateTokenResponse() {
if (updateTokenResponseBuilder_ == null) {
if (serverMessageCase_ == 7) {
serverMessageCase_ = 0;
serverMessage_ = null;
onChanged();
}
} else {
if (serverMessageCase_ == 7) {
serverMessageCase_ = 0;
serverMessage_ = null;
}
updateTokenResponseBuilder_.clear();
}
return this;
}
/**
* .Ydb.Topic.UpdateTokenResponse update_token_response = 7;
*/
public tech.ydb.proto.topic.YdbTopic.UpdateTokenResponse.Builder getUpdateTokenResponseBuilder() {
return getUpdateTokenResponseFieldBuilder().getBuilder();
}
/**
* .Ydb.Topic.UpdateTokenResponse update_token_response = 7;
*/
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.UpdateTokenResponseOrBuilder getUpdateTokenResponseOrBuilder() {
if ((serverMessageCase_ == 7) && (updateTokenResponseBuilder_ != null)) {
return updateTokenResponseBuilder_.getMessageOrBuilder();
} else {
if (serverMessageCase_ == 7) {
return (tech.ydb.proto.topic.YdbTopic.UpdateTokenResponse) serverMessage_;
}
return tech.ydb.proto.topic.YdbTopic.UpdateTokenResponse.getDefaultInstance();
}
}
/**
* .Ydb.Topic.UpdateTokenResponse update_token_response = 7;
*/
private com.google.protobuf.SingleFieldBuilderV3<
tech.ydb.proto.topic.YdbTopic.UpdateTokenResponse, tech.ydb.proto.topic.YdbTopic.UpdateTokenResponse.Builder, tech.ydb.proto.topic.YdbTopic.UpdateTokenResponseOrBuilder>
getUpdateTokenResponseFieldBuilder() {
if (updateTokenResponseBuilder_ == null) {
if (!(serverMessageCase_ == 7)) {
serverMessage_ = tech.ydb.proto.topic.YdbTopic.UpdateTokenResponse.getDefaultInstance();
}
updateTokenResponseBuilder_ = new com.google.protobuf.SingleFieldBuilderV3<
tech.ydb.proto.topic.YdbTopic.UpdateTokenResponse, tech.ydb.proto.topic.YdbTopic.UpdateTokenResponse.Builder, tech.ydb.proto.topic.YdbTopic.UpdateTokenResponseOrBuilder>(
(tech.ydb.proto.topic.YdbTopic.UpdateTokenResponse) serverMessage_,
getParentForChildren(),
isClean());
serverMessage_ = null;
}
serverMessageCase_ = 7;
onChanged();
return updateTokenResponseBuilder_;
}
private com.google.protobuf.SingleFieldBuilderV3<
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StartPartitionSessionRequest, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StartPartitionSessionRequest.Builder, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StartPartitionSessionRequestOrBuilder> startPartitionSessionRequestBuilder_;
/**
*
* Server commands.
*
*
* .Ydb.Topic.StreamReadMessage.StartPartitionSessionRequest start_partition_session_request = 8;
* @return Whether the startPartitionSessionRequest field is set.
*/
@java.lang.Override
public boolean hasStartPartitionSessionRequest() {
return serverMessageCase_ == 8;
}
/**
*
* Server commands.
*
*
* .Ydb.Topic.StreamReadMessage.StartPartitionSessionRequest start_partition_session_request = 8;
* @return The startPartitionSessionRequest.
*/
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StartPartitionSessionRequest getStartPartitionSessionRequest() {
if (startPartitionSessionRequestBuilder_ == null) {
if (serverMessageCase_ == 8) {
return (tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StartPartitionSessionRequest) serverMessage_;
}
return tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StartPartitionSessionRequest.getDefaultInstance();
} else {
if (serverMessageCase_ == 8) {
return startPartitionSessionRequestBuilder_.getMessage();
}
return tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StartPartitionSessionRequest.getDefaultInstance();
}
}
/**
*
* Server commands.
*
*
* .Ydb.Topic.StreamReadMessage.StartPartitionSessionRequest start_partition_session_request = 8;
*/
public Builder setStartPartitionSessionRequest(tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StartPartitionSessionRequest value) {
if (startPartitionSessionRequestBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
serverMessage_ = value;
onChanged();
} else {
startPartitionSessionRequestBuilder_.setMessage(value);
}
serverMessageCase_ = 8;
return this;
}
/**
*
* Server commands.
*
*
* .Ydb.Topic.StreamReadMessage.StartPartitionSessionRequest start_partition_session_request = 8;
*/
public Builder setStartPartitionSessionRequest(
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StartPartitionSessionRequest.Builder builderForValue) {
if (startPartitionSessionRequestBuilder_ == null) {
serverMessage_ = builderForValue.build();
onChanged();
} else {
startPartitionSessionRequestBuilder_.setMessage(builderForValue.build());
}
serverMessageCase_ = 8;
return this;
}
/**
*
* Server commands.
*
*
* .Ydb.Topic.StreamReadMessage.StartPartitionSessionRequest start_partition_session_request = 8;
*/
public Builder mergeStartPartitionSessionRequest(tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StartPartitionSessionRequest value) {
if (startPartitionSessionRequestBuilder_ == null) {
if (serverMessageCase_ == 8 &&
serverMessage_ != tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StartPartitionSessionRequest.getDefaultInstance()) {
serverMessage_ = tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StartPartitionSessionRequest.newBuilder((tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StartPartitionSessionRequest) serverMessage_)
.mergeFrom(value).buildPartial();
} else {
serverMessage_ = value;
}
onChanged();
} else {
if (serverMessageCase_ == 8) {
startPartitionSessionRequestBuilder_.mergeFrom(value);
} else {
startPartitionSessionRequestBuilder_.setMessage(value);
}
}
serverMessageCase_ = 8;
return this;
}
/**
*
* Server commands.
*
*
* .Ydb.Topic.StreamReadMessage.StartPartitionSessionRequest start_partition_session_request = 8;
*/
public Builder clearStartPartitionSessionRequest() {
if (startPartitionSessionRequestBuilder_ == null) {
if (serverMessageCase_ == 8) {
serverMessageCase_ = 0;
serverMessage_ = null;
onChanged();
}
} else {
if (serverMessageCase_ == 8) {
serverMessageCase_ = 0;
serverMessage_ = null;
}
startPartitionSessionRequestBuilder_.clear();
}
return this;
}
/**
*
* Server commands.
*
*
* .Ydb.Topic.StreamReadMessage.StartPartitionSessionRequest start_partition_session_request = 8;
*/
public tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StartPartitionSessionRequest.Builder getStartPartitionSessionRequestBuilder() {
return getStartPartitionSessionRequestFieldBuilder().getBuilder();
}
/**
*
* Server commands.
*
*
* .Ydb.Topic.StreamReadMessage.StartPartitionSessionRequest start_partition_session_request = 8;
*/
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StartPartitionSessionRequestOrBuilder getStartPartitionSessionRequestOrBuilder() {
if ((serverMessageCase_ == 8) && (startPartitionSessionRequestBuilder_ != null)) {
return startPartitionSessionRequestBuilder_.getMessageOrBuilder();
} else {
if (serverMessageCase_ == 8) {
return (tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StartPartitionSessionRequest) serverMessage_;
}
return tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StartPartitionSessionRequest.getDefaultInstance();
}
}
/**
*
* Server commands.
*
*
* .Ydb.Topic.StreamReadMessage.StartPartitionSessionRequest start_partition_session_request = 8;
*/
private com.google.protobuf.SingleFieldBuilderV3<
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StartPartitionSessionRequest, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StartPartitionSessionRequest.Builder, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StartPartitionSessionRequestOrBuilder>
getStartPartitionSessionRequestFieldBuilder() {
if (startPartitionSessionRequestBuilder_ == null) {
if (!(serverMessageCase_ == 8)) {
serverMessage_ = tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StartPartitionSessionRequest.getDefaultInstance();
}
startPartitionSessionRequestBuilder_ = new com.google.protobuf.SingleFieldBuilderV3<
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StartPartitionSessionRequest, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StartPartitionSessionRequest.Builder, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StartPartitionSessionRequestOrBuilder>(
(tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StartPartitionSessionRequest) serverMessage_,
getParentForChildren(),
isClean());
serverMessage_ = null;
}
serverMessageCase_ = 8;
onChanged();
return startPartitionSessionRequestBuilder_;
}
private com.google.protobuf.SingleFieldBuilderV3<
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StopPartitionSessionRequest, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StopPartitionSessionRequest.Builder, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StopPartitionSessionRequestOrBuilder> stopPartitionSessionRequestBuilder_;
/**
* .Ydb.Topic.StreamReadMessage.StopPartitionSessionRequest stop_partition_session_request = 9;
* @return Whether the stopPartitionSessionRequest field is set.
*/
@java.lang.Override
public boolean hasStopPartitionSessionRequest() {
return serverMessageCase_ == 9;
}
/**
* .Ydb.Topic.StreamReadMessage.StopPartitionSessionRequest stop_partition_session_request = 9;
* @return The stopPartitionSessionRequest.
*/
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StopPartitionSessionRequest getStopPartitionSessionRequest() {
if (stopPartitionSessionRequestBuilder_ == null) {
if (serverMessageCase_ == 9) {
return (tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StopPartitionSessionRequest) serverMessage_;
}
return tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StopPartitionSessionRequest.getDefaultInstance();
} else {
if (serverMessageCase_ == 9) {
return stopPartitionSessionRequestBuilder_.getMessage();
}
return tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StopPartitionSessionRequest.getDefaultInstance();
}
}
/**
* .Ydb.Topic.StreamReadMessage.StopPartitionSessionRequest stop_partition_session_request = 9;
*/
public Builder setStopPartitionSessionRequest(tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StopPartitionSessionRequest value) {
if (stopPartitionSessionRequestBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
serverMessage_ = value;
onChanged();
} else {
stopPartitionSessionRequestBuilder_.setMessage(value);
}
serverMessageCase_ = 9;
return this;
}
/**
* .Ydb.Topic.StreamReadMessage.StopPartitionSessionRequest stop_partition_session_request = 9;
*/
public Builder setStopPartitionSessionRequest(
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StopPartitionSessionRequest.Builder builderForValue) {
if (stopPartitionSessionRequestBuilder_ == null) {
serverMessage_ = builderForValue.build();
onChanged();
} else {
stopPartitionSessionRequestBuilder_.setMessage(builderForValue.build());
}
serverMessageCase_ = 9;
return this;
}
/**
* .Ydb.Topic.StreamReadMessage.StopPartitionSessionRequest stop_partition_session_request = 9;
*/
public Builder mergeStopPartitionSessionRequest(tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StopPartitionSessionRequest value) {
if (stopPartitionSessionRequestBuilder_ == null) {
if (serverMessageCase_ == 9 &&
serverMessage_ != tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StopPartitionSessionRequest.getDefaultInstance()) {
serverMessage_ = tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StopPartitionSessionRequest.newBuilder((tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StopPartitionSessionRequest) serverMessage_)
.mergeFrom(value).buildPartial();
} else {
serverMessage_ = value;
}
onChanged();
} else {
if (serverMessageCase_ == 9) {
stopPartitionSessionRequestBuilder_.mergeFrom(value);
} else {
stopPartitionSessionRequestBuilder_.setMessage(value);
}
}
serverMessageCase_ = 9;
return this;
}
/**
* .Ydb.Topic.StreamReadMessage.StopPartitionSessionRequest stop_partition_session_request = 9;
*/
public Builder clearStopPartitionSessionRequest() {
if (stopPartitionSessionRequestBuilder_ == null) {
if (serverMessageCase_ == 9) {
serverMessageCase_ = 0;
serverMessage_ = null;
onChanged();
}
} else {
if (serverMessageCase_ == 9) {
serverMessageCase_ = 0;
serverMessage_ = null;
}
stopPartitionSessionRequestBuilder_.clear();
}
return this;
}
/**
* .Ydb.Topic.StreamReadMessage.StopPartitionSessionRequest stop_partition_session_request = 9;
*/
public tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StopPartitionSessionRequest.Builder getStopPartitionSessionRequestBuilder() {
return getStopPartitionSessionRequestFieldBuilder().getBuilder();
}
/**
* .Ydb.Topic.StreamReadMessage.StopPartitionSessionRequest stop_partition_session_request = 9;
*/
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StopPartitionSessionRequestOrBuilder getStopPartitionSessionRequestOrBuilder() {
if ((serverMessageCase_ == 9) && (stopPartitionSessionRequestBuilder_ != null)) {
return stopPartitionSessionRequestBuilder_.getMessageOrBuilder();
} else {
if (serverMessageCase_ == 9) {
return (tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StopPartitionSessionRequest) serverMessage_;
}
return tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StopPartitionSessionRequest.getDefaultInstance();
}
}
/**
* .Ydb.Topic.StreamReadMessage.StopPartitionSessionRequest stop_partition_session_request = 9;
*/
private com.google.protobuf.SingleFieldBuilderV3<
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StopPartitionSessionRequest, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StopPartitionSessionRequest.Builder, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StopPartitionSessionRequestOrBuilder>
getStopPartitionSessionRequestFieldBuilder() {
if (stopPartitionSessionRequestBuilder_ == null) {
if (!(serverMessageCase_ == 9)) {
serverMessage_ = tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StopPartitionSessionRequest.getDefaultInstance();
}
stopPartitionSessionRequestBuilder_ = new com.google.protobuf.SingleFieldBuilderV3<
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StopPartitionSessionRequest, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StopPartitionSessionRequest.Builder, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StopPartitionSessionRequestOrBuilder>(
(tech.ydb.proto.topic.YdbTopic.StreamReadMessage.StopPartitionSessionRequest) serverMessage_,
getParentForChildren(),
isClean());
serverMessage_ = null;
}
serverMessageCase_ = 9;
onChanged();
return stopPartitionSessionRequestBuilder_;
}
private com.google.protobuf.SingleFieldBuilderV3<
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.UpdatePartitionSession, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.UpdatePartitionSession.Builder, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.UpdatePartitionSessionOrBuilder> updatePartitionSessionBuilder_;
/**
* .Ydb.Topic.StreamReadMessage.UpdatePartitionSession update_partition_session = 10;
* @return Whether the updatePartitionSession field is set.
*/
@java.lang.Override
public boolean hasUpdatePartitionSession() {
return serverMessageCase_ == 10;
}
/**
* .Ydb.Topic.StreamReadMessage.UpdatePartitionSession update_partition_session = 10;
* @return The updatePartitionSession.
*/
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamReadMessage.UpdatePartitionSession getUpdatePartitionSession() {
if (updatePartitionSessionBuilder_ == null) {
if (serverMessageCase_ == 10) {
return (tech.ydb.proto.topic.YdbTopic.StreamReadMessage.UpdatePartitionSession) serverMessage_;
}
return tech.ydb.proto.topic.YdbTopic.StreamReadMessage.UpdatePartitionSession.getDefaultInstance();
} else {
if (serverMessageCase_ == 10) {
return updatePartitionSessionBuilder_.getMessage();
}
return tech.ydb.proto.topic.YdbTopic.StreamReadMessage.UpdatePartitionSession.getDefaultInstance();
}
}
/**
* .Ydb.Topic.StreamReadMessage.UpdatePartitionSession update_partition_session = 10;
*/
public Builder setUpdatePartitionSession(tech.ydb.proto.topic.YdbTopic.StreamReadMessage.UpdatePartitionSession value) {
if (updatePartitionSessionBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
serverMessage_ = value;
onChanged();
} else {
updatePartitionSessionBuilder_.setMessage(value);
}
serverMessageCase_ = 10;
return this;
}
/**
* .Ydb.Topic.StreamReadMessage.UpdatePartitionSession update_partition_session = 10;
*/
public Builder setUpdatePartitionSession(
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.UpdatePartitionSession.Builder builderForValue) {
if (updatePartitionSessionBuilder_ == null) {
serverMessage_ = builderForValue.build();
onChanged();
} else {
updatePartitionSessionBuilder_.setMessage(builderForValue.build());
}
serverMessageCase_ = 10;
return this;
}
/**
* .Ydb.Topic.StreamReadMessage.UpdatePartitionSession update_partition_session = 10;
*/
public Builder mergeUpdatePartitionSession(tech.ydb.proto.topic.YdbTopic.StreamReadMessage.UpdatePartitionSession value) {
if (updatePartitionSessionBuilder_ == null) {
if (serverMessageCase_ == 10 &&
serverMessage_ != tech.ydb.proto.topic.YdbTopic.StreamReadMessage.UpdatePartitionSession.getDefaultInstance()) {
serverMessage_ = tech.ydb.proto.topic.YdbTopic.StreamReadMessage.UpdatePartitionSession.newBuilder((tech.ydb.proto.topic.YdbTopic.StreamReadMessage.UpdatePartitionSession) serverMessage_)
.mergeFrom(value).buildPartial();
} else {
serverMessage_ = value;
}
onChanged();
} else {
if (serverMessageCase_ == 10) {
updatePartitionSessionBuilder_.mergeFrom(value);
} else {
updatePartitionSessionBuilder_.setMessage(value);
}
}
serverMessageCase_ = 10;
return this;
}
/**
* .Ydb.Topic.StreamReadMessage.UpdatePartitionSession update_partition_session = 10;
*/
public Builder clearUpdatePartitionSession() {
if (updatePartitionSessionBuilder_ == null) {
if (serverMessageCase_ == 10) {
serverMessageCase_ = 0;
serverMessage_ = null;
onChanged();
}
} else {
if (serverMessageCase_ == 10) {
serverMessageCase_ = 0;
serverMessage_ = null;
}
updatePartitionSessionBuilder_.clear();
}
return this;
}
/**
* .Ydb.Topic.StreamReadMessage.UpdatePartitionSession update_partition_session = 10;
*/
public tech.ydb.proto.topic.YdbTopic.StreamReadMessage.UpdatePartitionSession.Builder getUpdatePartitionSessionBuilder() {
return getUpdatePartitionSessionFieldBuilder().getBuilder();
}
/**
* .Ydb.Topic.StreamReadMessage.UpdatePartitionSession update_partition_session = 10;
*/
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamReadMessage.UpdatePartitionSessionOrBuilder getUpdatePartitionSessionOrBuilder() {
if ((serverMessageCase_ == 10) && (updatePartitionSessionBuilder_ != null)) {
return updatePartitionSessionBuilder_.getMessageOrBuilder();
} else {
if (serverMessageCase_ == 10) {
return (tech.ydb.proto.topic.YdbTopic.StreamReadMessage.UpdatePartitionSession) serverMessage_;
}
return tech.ydb.proto.topic.YdbTopic.StreamReadMessage.UpdatePartitionSession.getDefaultInstance();
}
}
/**
* .Ydb.Topic.StreamReadMessage.UpdatePartitionSession update_partition_session = 10;
*/
private com.google.protobuf.SingleFieldBuilderV3<
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.UpdatePartitionSession, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.UpdatePartitionSession.Builder, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.UpdatePartitionSessionOrBuilder>
getUpdatePartitionSessionFieldBuilder() {
if (updatePartitionSessionBuilder_ == null) {
if (!(serverMessageCase_ == 10)) {
serverMessage_ = tech.ydb.proto.topic.YdbTopic.StreamReadMessage.UpdatePartitionSession.getDefaultInstance();
}
updatePartitionSessionBuilder_ = new com.google.protobuf.SingleFieldBuilderV3<
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.UpdatePartitionSession, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.UpdatePartitionSession.Builder, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.UpdatePartitionSessionOrBuilder>(
(tech.ydb.proto.topic.YdbTopic.StreamReadMessage.UpdatePartitionSession) serverMessage_,
getParentForChildren(),
isClean());
serverMessage_ = null;
}
serverMessageCase_ = 10;
onChanged();
return updatePartitionSessionBuilder_;
}
@java.lang.Override
public final Builder setUnknownFields(
final com.google.protobuf.UnknownFieldSet unknownFields) {
return super.setUnknownFields(unknownFields);
}
@java.lang.Override
public final Builder mergeUnknownFields(
final com.google.protobuf.UnknownFieldSet unknownFields) {
return super.mergeUnknownFields(unknownFields);
}
// @@protoc_insertion_point(builder_scope:Ydb.Topic.StreamReadMessage.FromServer)
}
// @@protoc_insertion_point(class_scope:Ydb.Topic.StreamReadMessage.FromServer)
private static final tech.ydb.proto.topic.YdbTopic.StreamReadMessage.FromServer DEFAULT_INSTANCE;
static {
DEFAULT_INSTANCE = new tech.ydb.proto.topic.YdbTopic.StreamReadMessage.FromServer();
}
public static tech.ydb.proto.topic.YdbTopic.StreamReadMessage.FromServer getDefaultInstance() {
return DEFAULT_INSTANCE;
}
private static final com.google.protobuf.Parser
PARSER = new com.google.protobuf.AbstractParser() {
@java.lang.Override
public FromServer parsePartialFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
Builder builder = newBuilder();
try {
builder.mergeFrom(input, extensionRegistry);
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.setUnfinishedMessage(builder.buildPartial());
} catch (com.google.protobuf.UninitializedMessageException e) {
throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial());
} catch (java.io.IOException e) {
throw new com.google.protobuf.InvalidProtocolBufferException(e)
.setUnfinishedMessage(builder.buildPartial());
}
return builder.buildPartial();
}
};
public static com.google.protobuf.Parser parser() {
return PARSER;
}
@java.lang.Override
public com.google.protobuf.Parser getParserForType() {
return PARSER;
}
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamReadMessage.FromServer getDefaultInstanceForType() {
return DEFAULT_INSTANCE;
}
}
public interface InitRequestOrBuilder extends
// @@protoc_insertion_point(interface_extends:Ydb.Topic.StreamReadMessage.InitRequest)
com.google.protobuf.MessageOrBuilder {
/**
*
* Message that describes topic to read.
* Topics that will be read by this session.
*
*
* repeated .Ydb.Topic.StreamReadMessage.InitRequest.TopicReadSettings topics_read_settings = 1;
*/
java.util.List
getTopicsReadSettingsList();
/**
*
* Message that describes topic to read.
* Topics that will be read by this session.
*
*
* repeated .Ydb.Topic.StreamReadMessage.InitRequest.TopicReadSettings topics_read_settings = 1;
*/
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest.TopicReadSettings getTopicsReadSettings(int index);
/**
*
* Message that describes topic to read.
* Topics that will be read by this session.
*
*
* repeated .Ydb.Topic.StreamReadMessage.InitRequest.TopicReadSettings topics_read_settings = 1;
*/
int getTopicsReadSettingsCount();
/**
*
* Message that describes topic to read.
* Topics that will be read by this session.
*
*
* repeated .Ydb.Topic.StreamReadMessage.InitRequest.TopicReadSettings topics_read_settings = 1;
*/
java.util.List extends tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest.TopicReadSettingsOrBuilder>
getTopicsReadSettingsOrBuilderList();
/**
*
* Message that describes topic to read.
* Topics that will be read by this session.
*
*
* repeated .Ydb.Topic.StreamReadMessage.InitRequest.TopicReadSettings topics_read_settings = 1;
*/
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest.TopicReadSettingsOrBuilder getTopicsReadSettingsOrBuilder(
int index);
/**
*
* Path of consumer that is used for reading by this session.
*
*
* string consumer = 2;
* @return The consumer.
*/
java.lang.String getConsumer();
/**
*
* Path of consumer that is used for reading by this session.
*
*
* string consumer = 2;
* @return The bytes for consumer.
*/
com.google.protobuf.ByteString
getConsumerBytes();
/**
*
* Optional name. Will be shown in debug stat.
*
*
* string reader_name = 3;
* @return The readerName.
*/
java.lang.String getReaderName();
/**
*
* Optional name. Will be shown in debug stat.
*
*
* string reader_name = 3;
* @return The bytes for readerName.
*/
com.google.protobuf.ByteString
getReaderNameBytes();
/**
*
* Direct reading from a partition node.
*
*
* bool direct_read = 4;
* @return The directRead.
*/
boolean getDirectRead();
}
/**
*
* Handshake request.
*
*
* Protobuf type {@code Ydb.Topic.StreamReadMessage.InitRequest}
*/
public static final class InitRequest extends
com.google.protobuf.GeneratedMessageV3 implements
// @@protoc_insertion_point(message_implements:Ydb.Topic.StreamReadMessage.InitRequest)
InitRequestOrBuilder {
private static final long serialVersionUID = 0L;
// Use InitRequest.newBuilder() to construct.
private InitRequest(com.google.protobuf.GeneratedMessageV3.Builder> builder) {
super(builder);
}
private InitRequest() {
topicsReadSettings_ = java.util.Collections.emptyList();
consumer_ = "";
readerName_ = "";
}
@java.lang.Override
@SuppressWarnings({"unused"})
protected java.lang.Object newInstance(
UnusedPrivateParameter unused) {
return new InitRequest();
}
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_StreamReadMessage_InitRequest_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_StreamReadMessage_InitRequest_fieldAccessorTable
.ensureFieldAccessorsInitialized(
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest.class, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest.Builder.class);
}
public interface TopicReadSettingsOrBuilder extends
// @@protoc_insertion_point(interface_extends:Ydb.Topic.StreamReadMessage.InitRequest.TopicReadSettings)
com.google.protobuf.MessageOrBuilder {
/**
*
* Topic path.
*
*
* string path = 1;
* @return The path.
*/
java.lang.String getPath();
/**
*
* Topic path.
*
*
* string path = 1;
* @return The bytes for path.
*/
com.google.protobuf.ByteString
getPathBytes();
/**
*
* Partitions that will be read by this session.
* If list is empty - then session will read all partitions.
*
*
* repeated int64 partition_ids = 2;
* @return A list containing the partitionIds.
*/
java.util.List getPartitionIdsList();
/**
*
* Partitions that will be read by this session.
* If list is empty - then session will read all partitions.
*
*
* repeated int64 partition_ids = 2;
* @return The count of partitionIds.
*/
int getPartitionIdsCount();
/**
*
* Partitions that will be read by this session.
* If list is empty - then session will read all partitions.
*
*
* repeated int64 partition_ids = 2;
* @param index The index of the element to return.
* @return The partitionIds at the given index.
*/
long getPartitionIds(int index);
/**
*
* Skip all messages that has write timestamp smaller than now - max_lag.
* Zero means infinite lag.
*
*
* .google.protobuf.Duration max_lag = 3;
* @return Whether the maxLag field is set.
*/
boolean hasMaxLag();
/**
*
* Skip all messages that has write timestamp smaller than now - max_lag.
* Zero means infinite lag.
*
*
* .google.protobuf.Duration max_lag = 3;
* @return The maxLag.
*/
com.google.protobuf.Duration getMaxLag();
/**
*
* Skip all messages that has write timestamp smaller than now - max_lag.
* Zero means infinite lag.
*
*
* .google.protobuf.Duration max_lag = 3;
*/
com.google.protobuf.DurationOrBuilder getMaxLagOrBuilder();
/**
*
* Read data only after this timestamp from this topic.
* Read only messages with 'written_at' value greater or equal than this timestamp.
*
*
* .google.protobuf.Timestamp read_from = 4;
* @return Whether the readFrom field is set.
*/
boolean hasReadFrom();
/**
*
* Read data only after this timestamp from this topic.
* Read only messages with 'written_at' value greater or equal than this timestamp.
*
*
* .google.protobuf.Timestamp read_from = 4;
* @return The readFrom.
*/
com.google.protobuf.Timestamp getReadFrom();
/**
*
* Read data only after this timestamp from this topic.
* Read only messages with 'written_at' value greater or equal than this timestamp.
*
*
* .google.protobuf.Timestamp read_from = 4;
*/
com.google.protobuf.TimestampOrBuilder getReadFromOrBuilder();
}
/**
* Protobuf type {@code Ydb.Topic.StreamReadMessage.InitRequest.TopicReadSettings}
*/
public static final class TopicReadSettings extends
com.google.protobuf.GeneratedMessageV3 implements
// @@protoc_insertion_point(message_implements:Ydb.Topic.StreamReadMessage.InitRequest.TopicReadSettings)
TopicReadSettingsOrBuilder {
private static final long serialVersionUID = 0L;
// Use TopicReadSettings.newBuilder() to construct.
private TopicReadSettings(com.google.protobuf.GeneratedMessageV3.Builder> builder) {
super(builder);
}
private TopicReadSettings() {
path_ = "";
partitionIds_ = emptyLongList();
}
@java.lang.Override
@SuppressWarnings({"unused"})
protected java.lang.Object newInstance(
UnusedPrivateParameter unused) {
return new TopicReadSettings();
}
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_StreamReadMessage_InitRequest_TopicReadSettings_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_StreamReadMessage_InitRequest_TopicReadSettings_fieldAccessorTable
.ensureFieldAccessorsInitialized(
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest.TopicReadSettings.class, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest.TopicReadSettings.Builder.class);
}
private int bitField0_;
public static final int PATH_FIELD_NUMBER = 1;
@SuppressWarnings("serial")
private volatile java.lang.Object path_ = "";
/**
*
* Topic path.
*
*
* string path = 1;
* @return The path.
*/
@java.lang.Override
public java.lang.String getPath() {
java.lang.Object ref = path_;
if (ref instanceof java.lang.String) {
return (java.lang.String) ref;
} else {
com.google.protobuf.ByteString bs =
(com.google.protobuf.ByteString) ref;
java.lang.String s = bs.toStringUtf8();
path_ = s;
return s;
}
}
/**
*
* Topic path.
*
*
* string path = 1;
* @return The bytes for path.
*/
@java.lang.Override
public com.google.protobuf.ByteString
getPathBytes() {
java.lang.Object ref = path_;
if (ref instanceof java.lang.String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
path_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
public static final int PARTITION_IDS_FIELD_NUMBER = 2;
@SuppressWarnings("serial")
private com.google.protobuf.Internal.LongList partitionIds_ =
emptyLongList();
/**
*
* Partitions that will be read by this session.
* If list is empty - then session will read all partitions.
*
*
* repeated int64 partition_ids = 2;
* @return A list containing the partitionIds.
*/
@java.lang.Override
public java.util.List
getPartitionIdsList() {
return partitionIds_;
}
/**
*
* Partitions that will be read by this session.
* If list is empty - then session will read all partitions.
*
*
* repeated int64 partition_ids = 2;
* @return The count of partitionIds.
*/
public int getPartitionIdsCount() {
return partitionIds_.size();
}
/**
*
* Partitions that will be read by this session.
* If list is empty - then session will read all partitions.
*
*
* repeated int64 partition_ids = 2;
* @param index The index of the element to return.
* @return The partitionIds at the given index.
*/
public long getPartitionIds(int index) {
return partitionIds_.getLong(index);
}
private int partitionIdsMemoizedSerializedSize = -1;
public static final int MAX_LAG_FIELD_NUMBER = 3;
private com.google.protobuf.Duration maxLag_;
/**
*
* Skip all messages that has write timestamp smaller than now - max_lag.
* Zero means infinite lag.
*
*
* .google.protobuf.Duration max_lag = 3;
* @return Whether the maxLag field is set.
*/
@java.lang.Override
public boolean hasMaxLag() {
return ((bitField0_ & 0x00000001) != 0);
}
/**
*
* Skip all messages that has write timestamp smaller than now - max_lag.
* Zero means infinite lag.
*
*
* .google.protobuf.Duration max_lag = 3;
* @return The maxLag.
*/
@java.lang.Override
public com.google.protobuf.Duration getMaxLag() {
return maxLag_ == null ? com.google.protobuf.Duration.getDefaultInstance() : maxLag_;
}
/**
*
* Skip all messages that has write timestamp smaller than now - max_lag.
* Zero means infinite lag.
*
*
* .google.protobuf.Duration max_lag = 3;
*/
@java.lang.Override
public com.google.protobuf.DurationOrBuilder getMaxLagOrBuilder() {
return maxLag_ == null ? com.google.protobuf.Duration.getDefaultInstance() : maxLag_;
}
public static final int READ_FROM_FIELD_NUMBER = 4;
private com.google.protobuf.Timestamp readFrom_;
/**
*
* Read data only after this timestamp from this topic.
* Read only messages with 'written_at' value greater or equal than this timestamp.
*
*
* .google.protobuf.Timestamp read_from = 4;
* @return Whether the readFrom field is set.
*/
@java.lang.Override
public boolean hasReadFrom() {
return ((bitField0_ & 0x00000002) != 0);
}
/**
*
* Read data only after this timestamp from this topic.
* Read only messages with 'written_at' value greater or equal than this timestamp.
*
*
* .google.protobuf.Timestamp read_from = 4;
* @return The readFrom.
*/
@java.lang.Override
public com.google.protobuf.Timestamp getReadFrom() {
return readFrom_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : readFrom_;
}
/**
*
* Read data only after this timestamp from this topic.
* Read only messages with 'written_at' value greater or equal than this timestamp.
*
*
* .google.protobuf.Timestamp read_from = 4;
*/
@java.lang.Override
public com.google.protobuf.TimestampOrBuilder getReadFromOrBuilder() {
return readFrom_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : readFrom_;
}
private byte memoizedIsInitialized = -1;
@java.lang.Override
public final boolean isInitialized() {
byte isInitialized = memoizedIsInitialized;
if (isInitialized == 1) return true;
if (isInitialized == 0) return false;
memoizedIsInitialized = 1;
return true;
}
@java.lang.Override
public void writeTo(com.google.protobuf.CodedOutputStream output)
throws java.io.IOException {
getSerializedSize();
if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(path_)) {
com.google.protobuf.GeneratedMessageV3.writeString(output, 1, path_);
}
if (getPartitionIdsList().size() > 0) {
output.writeUInt32NoTag(18);
output.writeUInt32NoTag(partitionIdsMemoizedSerializedSize);
}
for (int i = 0; i < partitionIds_.size(); i++) {
output.writeInt64NoTag(partitionIds_.getLong(i));
}
if (((bitField0_ & 0x00000001) != 0)) {
output.writeMessage(3, getMaxLag());
}
if (((bitField0_ & 0x00000002) != 0)) {
output.writeMessage(4, getReadFrom());
}
getUnknownFields().writeTo(output);
}
@java.lang.Override
public int getSerializedSize() {
int size = memoizedSize;
if (size != -1) return size;
size = 0;
if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(path_)) {
size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, path_);
}
{
int dataSize = 0;
for (int i = 0; i < partitionIds_.size(); i++) {
dataSize += com.google.protobuf.CodedOutputStream
.computeInt64SizeNoTag(partitionIds_.getLong(i));
}
size += dataSize;
if (!getPartitionIdsList().isEmpty()) {
size += 1;
size += com.google.protobuf.CodedOutputStream
.computeInt32SizeNoTag(dataSize);
}
partitionIdsMemoizedSerializedSize = dataSize;
}
if (((bitField0_ & 0x00000001) != 0)) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(3, getMaxLag());
}
if (((bitField0_ & 0x00000002) != 0)) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(4, getReadFrom());
}
size += getUnknownFields().getSerializedSize();
memoizedSize = size;
return size;
}
@java.lang.Override
public boolean equals(final java.lang.Object obj) {
if (obj == this) {
return true;
}
if (!(obj instanceof tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest.TopicReadSettings)) {
return super.equals(obj);
}
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest.TopicReadSettings other = (tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest.TopicReadSettings) obj;
if (!getPath()
.equals(other.getPath())) return false;
if (!getPartitionIdsList()
.equals(other.getPartitionIdsList())) return false;
if (hasMaxLag() != other.hasMaxLag()) return false;
if (hasMaxLag()) {
if (!getMaxLag()
.equals(other.getMaxLag())) return false;
}
if (hasReadFrom() != other.hasReadFrom()) return false;
if (hasReadFrom()) {
if (!getReadFrom()
.equals(other.getReadFrom())) return false;
}
if (!getUnknownFields().equals(other.getUnknownFields())) return false;
return true;
}
@java.lang.Override
public int hashCode() {
if (memoizedHashCode != 0) {
return memoizedHashCode;
}
int hash = 41;
hash = (19 * hash) + getDescriptor().hashCode();
hash = (37 * hash) + PATH_FIELD_NUMBER;
hash = (53 * hash) + getPath().hashCode();
if (getPartitionIdsCount() > 0) {
hash = (37 * hash) + PARTITION_IDS_FIELD_NUMBER;
hash = (53 * hash) + getPartitionIdsList().hashCode();
}
if (hasMaxLag()) {
hash = (37 * hash) + MAX_LAG_FIELD_NUMBER;
hash = (53 * hash) + getMaxLag().hashCode();
}
if (hasReadFrom()) {
hash = (37 * hash) + READ_FROM_FIELD_NUMBER;
hash = (53 * hash) + getReadFrom().hashCode();
}
hash = (29 * hash) + getUnknownFields().hashCode();
memoizedHashCode = hash;
return hash;
}
public static tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest.TopicReadSettings parseFrom(
java.nio.ByteBuffer data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest.TopicReadSettings parseFrom(
java.nio.ByteBuffer data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest.TopicReadSettings parseFrom(
com.google.protobuf.ByteString data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest.TopicReadSettings parseFrom(
com.google.protobuf.ByteString data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest.TopicReadSettings parseFrom(byte[] data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest.TopicReadSettings parseFrom(
byte[] data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest.TopicReadSettings parseFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest.TopicReadSettings parseFrom(
java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest.TopicReadSettings parseDelimitedFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input);
}
public static tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest.TopicReadSettings parseDelimitedFrom(
java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest.TopicReadSettings parseFrom(
com.google.protobuf.CodedInputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest.TopicReadSettings parseFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry);
}
@java.lang.Override
public Builder newBuilderForType() { return newBuilder(); }
public static Builder newBuilder() {
return DEFAULT_INSTANCE.toBuilder();
}
public static Builder newBuilder(tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest.TopicReadSettings prototype) {
return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
}
@java.lang.Override
public Builder toBuilder() {
return this == DEFAULT_INSTANCE
? new Builder() : new Builder().mergeFrom(this);
}
@java.lang.Override
protected Builder newBuilderForType(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
Builder builder = new Builder(parent);
return builder;
}
/**
* Protobuf type {@code Ydb.Topic.StreamReadMessage.InitRequest.TopicReadSettings}
*/
public static final class Builder extends
com.google.protobuf.GeneratedMessageV3.Builder implements
// @@protoc_insertion_point(builder_implements:Ydb.Topic.StreamReadMessage.InitRequest.TopicReadSettings)
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest.TopicReadSettingsOrBuilder {
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_StreamReadMessage_InitRequest_TopicReadSettings_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_StreamReadMessage_InitRequest_TopicReadSettings_fieldAccessorTable
.ensureFieldAccessorsInitialized(
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest.TopicReadSettings.class, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest.TopicReadSettings.Builder.class);
}
// Construct using tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest.TopicReadSettings.newBuilder()
private Builder() {
maybeForceBuilderInitialization();
}
private Builder(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
super(parent);
maybeForceBuilderInitialization();
}
private void maybeForceBuilderInitialization() {
if (com.google.protobuf.GeneratedMessageV3
.alwaysUseFieldBuilders) {
getMaxLagFieldBuilder();
getReadFromFieldBuilder();
}
}
@java.lang.Override
public Builder clear() {
super.clear();
bitField0_ = 0;
path_ = "";
partitionIds_ = emptyLongList();
maxLag_ = null;
if (maxLagBuilder_ != null) {
maxLagBuilder_.dispose();
maxLagBuilder_ = null;
}
readFrom_ = null;
if (readFromBuilder_ != null) {
readFromBuilder_.dispose();
readFromBuilder_ = null;
}
return this;
}
@java.lang.Override
public com.google.protobuf.Descriptors.Descriptor
getDescriptorForType() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_StreamReadMessage_InitRequest_TopicReadSettings_descriptor;
}
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest.TopicReadSettings getDefaultInstanceForType() {
return tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest.TopicReadSettings.getDefaultInstance();
}
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest.TopicReadSettings build() {
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest.TopicReadSettings result = buildPartial();
if (!result.isInitialized()) {
throw newUninitializedMessageException(result);
}
return result;
}
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest.TopicReadSettings buildPartial() {
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest.TopicReadSettings result = new tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest.TopicReadSettings(this);
if (bitField0_ != 0) { buildPartial0(result); }
onBuilt();
return result;
}
private void buildPartial0(tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest.TopicReadSettings result) {
int from_bitField0_ = bitField0_;
if (((from_bitField0_ & 0x00000001) != 0)) {
result.path_ = path_;
}
if (((from_bitField0_ & 0x00000002) != 0)) {
partitionIds_.makeImmutable();
result.partitionIds_ = partitionIds_;
}
int to_bitField0_ = 0;
if (((from_bitField0_ & 0x00000004) != 0)) {
result.maxLag_ = maxLagBuilder_ == null
? maxLag_
: maxLagBuilder_.build();
to_bitField0_ |= 0x00000001;
}
if (((from_bitField0_ & 0x00000008) != 0)) {
result.readFrom_ = readFromBuilder_ == null
? readFrom_
: readFromBuilder_.build();
to_bitField0_ |= 0x00000002;
}
result.bitField0_ |= to_bitField0_;
}
@java.lang.Override
public Builder clone() {
return super.clone();
}
@java.lang.Override
public Builder setField(
com.google.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) {
return super.setField(field, value);
}
@java.lang.Override
public Builder clearField(
com.google.protobuf.Descriptors.FieldDescriptor field) {
return super.clearField(field);
}
@java.lang.Override
public Builder clearOneof(
com.google.protobuf.Descriptors.OneofDescriptor oneof) {
return super.clearOneof(oneof);
}
@java.lang.Override
public Builder setRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
int index, java.lang.Object value) {
return super.setRepeatedField(field, index, value);
}
@java.lang.Override
public Builder addRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) {
return super.addRepeatedField(field, value);
}
@java.lang.Override
public Builder mergeFrom(com.google.protobuf.Message other) {
if (other instanceof tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest.TopicReadSettings) {
return mergeFrom((tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest.TopicReadSettings)other);
} else {
super.mergeFrom(other);
return this;
}
}
public Builder mergeFrom(tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest.TopicReadSettings other) {
if (other == tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest.TopicReadSettings.getDefaultInstance()) return this;
if (!other.getPath().isEmpty()) {
path_ = other.path_;
bitField0_ |= 0x00000001;
onChanged();
}
if (!other.partitionIds_.isEmpty()) {
if (partitionIds_.isEmpty()) {
partitionIds_ = other.partitionIds_;
partitionIds_.makeImmutable();
bitField0_ |= 0x00000002;
} else {
ensurePartitionIdsIsMutable();
partitionIds_.addAll(other.partitionIds_);
}
onChanged();
}
if (other.hasMaxLag()) {
mergeMaxLag(other.getMaxLag());
}
if (other.hasReadFrom()) {
mergeReadFrom(other.getReadFrom());
}
this.mergeUnknownFields(other.getUnknownFields());
onChanged();
return this;
}
@java.lang.Override
public final boolean isInitialized() {
return true;
}
@java.lang.Override
public Builder mergeFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
if (extensionRegistry == null) {
throw new java.lang.NullPointerException();
}
try {
boolean done = false;
while (!done) {
int tag = input.readTag();
switch (tag) {
case 0:
done = true;
break;
case 10: {
path_ = input.readStringRequireUtf8();
bitField0_ |= 0x00000001;
break;
} // case 10
case 16: {
long v = input.readInt64();
ensurePartitionIdsIsMutable();
partitionIds_.addLong(v);
break;
} // case 16
case 18: {
int length = input.readRawVarint32();
int limit = input.pushLimit(length);
ensurePartitionIdsIsMutable();
while (input.getBytesUntilLimit() > 0) {
partitionIds_.addLong(input.readInt64());
}
input.popLimit(limit);
break;
} // case 18
case 26: {
input.readMessage(
getMaxLagFieldBuilder().getBuilder(),
extensionRegistry);
bitField0_ |= 0x00000004;
break;
} // case 26
case 34: {
input.readMessage(
getReadFromFieldBuilder().getBuilder(),
extensionRegistry);
bitField0_ |= 0x00000008;
break;
} // case 34
default: {
if (!super.parseUnknownField(input, extensionRegistry, tag)) {
done = true; // was an endgroup tag
}
break;
} // default:
} // switch (tag)
} // while (!done)
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.unwrapIOException();
} finally {
onChanged();
} // finally
return this;
}
private int bitField0_;
private java.lang.Object path_ = "";
/**
*
* Topic path.
*
*
* string path = 1;
* @return The path.
*/
public java.lang.String getPath() {
java.lang.Object ref = path_;
if (!(ref instanceof java.lang.String)) {
com.google.protobuf.ByteString bs =
(com.google.protobuf.ByteString) ref;
java.lang.String s = bs.toStringUtf8();
path_ = s;
return s;
} else {
return (java.lang.String) ref;
}
}
/**
*
* Topic path.
*
*
* string path = 1;
* @return The bytes for path.
*/
public com.google.protobuf.ByteString
getPathBytes() {
java.lang.Object ref = path_;
if (ref instanceof String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
path_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
/**
*
* Topic path.
*
*
* string path = 1;
* @param value The path to set.
* @return This builder for chaining.
*/
public Builder setPath(
java.lang.String value) {
if (value == null) { throw new NullPointerException(); }
path_ = value;
bitField0_ |= 0x00000001;
onChanged();
return this;
}
/**
*
* Topic path.
*
*
* string path = 1;
* @return This builder for chaining.
*/
public Builder clearPath() {
path_ = getDefaultInstance().getPath();
bitField0_ = (bitField0_ & ~0x00000001);
onChanged();
return this;
}
/**
*
* Topic path.
*
*
* string path = 1;
* @param value The bytes for path to set.
* @return This builder for chaining.
*/
public Builder setPathBytes(
com.google.protobuf.ByteString value) {
if (value == null) { throw new NullPointerException(); }
checkByteStringIsUtf8(value);
path_ = value;
bitField0_ |= 0x00000001;
onChanged();
return this;
}
private com.google.protobuf.Internal.LongList partitionIds_ = emptyLongList();
private void ensurePartitionIdsIsMutable() {
if (!partitionIds_.isModifiable()) {
partitionIds_ = makeMutableCopy(partitionIds_);
}
bitField0_ |= 0x00000002;
}
/**
*
* Partitions that will be read by this session.
* If list is empty - then session will read all partitions.
*
*
* repeated int64 partition_ids = 2;
* @return A list containing the partitionIds.
*/
public java.util.List
getPartitionIdsList() {
partitionIds_.makeImmutable();
return partitionIds_;
}
/**
*
* Partitions that will be read by this session.
* If list is empty - then session will read all partitions.
*
*
* repeated int64 partition_ids = 2;
* @return The count of partitionIds.
*/
public int getPartitionIdsCount() {
return partitionIds_.size();
}
/**
*
* Partitions that will be read by this session.
* If list is empty - then session will read all partitions.
*
*
* repeated int64 partition_ids = 2;
* @param index The index of the element to return.
* @return The partitionIds at the given index.
*/
public long getPartitionIds(int index) {
return partitionIds_.getLong(index);
}
/**
*
* Partitions that will be read by this session.
* If list is empty - then session will read all partitions.
*
*
* repeated int64 partition_ids = 2;
* @param index The index to set the value at.
* @param value The partitionIds to set.
* @return This builder for chaining.
*/
public Builder setPartitionIds(
int index, long value) {
ensurePartitionIdsIsMutable();
partitionIds_.setLong(index, value);
bitField0_ |= 0x00000002;
onChanged();
return this;
}
/**
*
* Partitions that will be read by this session.
* If list is empty - then session will read all partitions.
*
*
* repeated int64 partition_ids = 2;
* @param value The partitionIds to add.
* @return This builder for chaining.
*/
public Builder addPartitionIds(long value) {
ensurePartitionIdsIsMutable();
partitionIds_.addLong(value);
bitField0_ |= 0x00000002;
onChanged();
return this;
}
/**
*
* Partitions that will be read by this session.
* If list is empty - then session will read all partitions.
*
*
* repeated int64 partition_ids = 2;
* @param values The partitionIds to add.
* @return This builder for chaining.
*/
public Builder addAllPartitionIds(
java.lang.Iterable extends java.lang.Long> values) {
ensurePartitionIdsIsMutable();
com.google.protobuf.AbstractMessageLite.Builder.addAll(
values, partitionIds_);
bitField0_ |= 0x00000002;
onChanged();
return this;
}
/**
*
* Partitions that will be read by this session.
* If list is empty - then session will read all partitions.
*
*
* repeated int64 partition_ids = 2;
* @return This builder for chaining.
*/
public Builder clearPartitionIds() {
partitionIds_ = emptyLongList();
bitField0_ = (bitField0_ & ~0x00000002);
onChanged();
return this;
}
private com.google.protobuf.Duration maxLag_;
private com.google.protobuf.SingleFieldBuilderV3<
com.google.protobuf.Duration, com.google.protobuf.Duration.Builder, com.google.protobuf.DurationOrBuilder> maxLagBuilder_;
/**
*
* Skip all messages that has write timestamp smaller than now - max_lag.
* Zero means infinite lag.
*
*
* .google.protobuf.Duration max_lag = 3;
* @return Whether the maxLag field is set.
*/
public boolean hasMaxLag() {
return ((bitField0_ & 0x00000004) != 0);
}
/**
*
* Skip all messages that has write timestamp smaller than now - max_lag.
* Zero means infinite lag.
*
*
* .google.protobuf.Duration max_lag = 3;
* @return The maxLag.
*/
public com.google.protobuf.Duration getMaxLag() {
if (maxLagBuilder_ == null) {
return maxLag_ == null ? com.google.protobuf.Duration.getDefaultInstance() : maxLag_;
} else {
return maxLagBuilder_.getMessage();
}
}
/**
*
* Skip all messages that has write timestamp smaller than now - max_lag.
* Zero means infinite lag.
*
*
* .google.protobuf.Duration max_lag = 3;
*/
public Builder setMaxLag(com.google.protobuf.Duration value) {
if (maxLagBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
maxLag_ = value;
} else {
maxLagBuilder_.setMessage(value);
}
bitField0_ |= 0x00000004;
onChanged();
return this;
}
/**
*
* Skip all messages that has write timestamp smaller than now - max_lag.
* Zero means infinite lag.
*
*
* .google.protobuf.Duration max_lag = 3;
*/
public Builder setMaxLag(
com.google.protobuf.Duration.Builder builderForValue) {
if (maxLagBuilder_ == null) {
maxLag_ = builderForValue.build();
} else {
maxLagBuilder_.setMessage(builderForValue.build());
}
bitField0_ |= 0x00000004;
onChanged();
return this;
}
/**
*
* Skip all messages that has write timestamp smaller than now - max_lag.
* Zero means infinite lag.
*
*
* .google.protobuf.Duration max_lag = 3;
*/
public Builder mergeMaxLag(com.google.protobuf.Duration value) {
if (maxLagBuilder_ == null) {
if (((bitField0_ & 0x00000004) != 0) &&
maxLag_ != null &&
maxLag_ != com.google.protobuf.Duration.getDefaultInstance()) {
getMaxLagBuilder().mergeFrom(value);
} else {
maxLag_ = value;
}
} else {
maxLagBuilder_.mergeFrom(value);
}
if (maxLag_ != null) {
bitField0_ |= 0x00000004;
onChanged();
}
return this;
}
/**
*
* Skip all messages that has write timestamp smaller than now - max_lag.
* Zero means infinite lag.
*
*
* .google.protobuf.Duration max_lag = 3;
*/
public Builder clearMaxLag() {
bitField0_ = (bitField0_ & ~0x00000004);
maxLag_ = null;
if (maxLagBuilder_ != null) {
maxLagBuilder_.dispose();
maxLagBuilder_ = null;
}
onChanged();
return this;
}
/**
*
* Skip all messages that has write timestamp smaller than now - max_lag.
* Zero means infinite lag.
*
*
* .google.protobuf.Duration max_lag = 3;
*/
public com.google.protobuf.Duration.Builder getMaxLagBuilder() {
bitField0_ |= 0x00000004;
onChanged();
return getMaxLagFieldBuilder().getBuilder();
}
/**
*
* Skip all messages that has write timestamp smaller than now - max_lag.
* Zero means infinite lag.
*
*
* .google.protobuf.Duration max_lag = 3;
*/
public com.google.protobuf.DurationOrBuilder getMaxLagOrBuilder() {
if (maxLagBuilder_ != null) {
return maxLagBuilder_.getMessageOrBuilder();
} else {
return maxLag_ == null ?
com.google.protobuf.Duration.getDefaultInstance() : maxLag_;
}
}
/**
*
* Skip all messages that has write timestamp smaller than now - max_lag.
* Zero means infinite lag.
*
*
* .google.protobuf.Duration max_lag = 3;
*/
private com.google.protobuf.SingleFieldBuilderV3<
com.google.protobuf.Duration, com.google.protobuf.Duration.Builder, com.google.protobuf.DurationOrBuilder>
getMaxLagFieldBuilder() {
if (maxLagBuilder_ == null) {
maxLagBuilder_ = new com.google.protobuf.SingleFieldBuilderV3<
com.google.protobuf.Duration, com.google.protobuf.Duration.Builder, com.google.protobuf.DurationOrBuilder>(
getMaxLag(),
getParentForChildren(),
isClean());
maxLag_ = null;
}
return maxLagBuilder_;
}
private com.google.protobuf.Timestamp readFrom_;
private com.google.protobuf.SingleFieldBuilderV3<
com.google.protobuf.Timestamp, com.google.protobuf.Timestamp.Builder, com.google.protobuf.TimestampOrBuilder> readFromBuilder_;
/**
*
* Read data only after this timestamp from this topic.
* Read only messages with 'written_at' value greater or equal than this timestamp.
*
*
* .google.protobuf.Timestamp read_from = 4;
* @return Whether the readFrom field is set.
*/
public boolean hasReadFrom() {
return ((bitField0_ & 0x00000008) != 0);
}
/**
*
* Read data only after this timestamp from this topic.
* Read only messages with 'written_at' value greater or equal than this timestamp.
*
*
* .google.protobuf.Timestamp read_from = 4;
* @return The readFrom.
*/
public com.google.protobuf.Timestamp getReadFrom() {
if (readFromBuilder_ == null) {
return readFrom_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : readFrom_;
} else {
return readFromBuilder_.getMessage();
}
}
/**
*
* Read data only after this timestamp from this topic.
* Read only messages with 'written_at' value greater or equal than this timestamp.
*
*
* .google.protobuf.Timestamp read_from = 4;
*/
public Builder setReadFrom(com.google.protobuf.Timestamp value) {
if (readFromBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
readFrom_ = value;
} else {
readFromBuilder_.setMessage(value);
}
bitField0_ |= 0x00000008;
onChanged();
return this;
}
/**
*
* Read data only after this timestamp from this topic.
* Read only messages with 'written_at' value greater or equal than this timestamp.
*
*
* .google.protobuf.Timestamp read_from = 4;
*/
public Builder setReadFrom(
com.google.protobuf.Timestamp.Builder builderForValue) {
if (readFromBuilder_ == null) {
readFrom_ = builderForValue.build();
} else {
readFromBuilder_.setMessage(builderForValue.build());
}
bitField0_ |= 0x00000008;
onChanged();
return this;
}
/**
*
* Read data only after this timestamp from this topic.
* Read only messages with 'written_at' value greater or equal than this timestamp.
*
*
* .google.protobuf.Timestamp read_from = 4;
*/
public Builder mergeReadFrom(com.google.protobuf.Timestamp value) {
if (readFromBuilder_ == null) {
if (((bitField0_ & 0x00000008) != 0) &&
readFrom_ != null &&
readFrom_ != com.google.protobuf.Timestamp.getDefaultInstance()) {
getReadFromBuilder().mergeFrom(value);
} else {
readFrom_ = value;
}
} else {
readFromBuilder_.mergeFrom(value);
}
if (readFrom_ != null) {
bitField0_ |= 0x00000008;
onChanged();
}
return this;
}
/**
*
* Read data only after this timestamp from this topic.
* Read only messages with 'written_at' value greater or equal than this timestamp.
*
*
* .google.protobuf.Timestamp read_from = 4;
*/
public Builder clearReadFrom() {
bitField0_ = (bitField0_ & ~0x00000008);
readFrom_ = null;
if (readFromBuilder_ != null) {
readFromBuilder_.dispose();
readFromBuilder_ = null;
}
onChanged();
return this;
}
/**
*
* Read data only after this timestamp from this topic.
* Read only messages with 'written_at' value greater or equal than this timestamp.
*
*
* .google.protobuf.Timestamp read_from = 4;
*/
public com.google.protobuf.Timestamp.Builder getReadFromBuilder() {
bitField0_ |= 0x00000008;
onChanged();
return getReadFromFieldBuilder().getBuilder();
}
/**
*
* Read data only after this timestamp from this topic.
* Read only messages with 'written_at' value greater or equal than this timestamp.
*
*
* .google.protobuf.Timestamp read_from = 4;
*/
public com.google.protobuf.TimestampOrBuilder getReadFromOrBuilder() {
if (readFromBuilder_ != null) {
return readFromBuilder_.getMessageOrBuilder();
} else {
return readFrom_ == null ?
com.google.protobuf.Timestamp.getDefaultInstance() : readFrom_;
}
}
/**
*
* Read data only after this timestamp from this topic.
* Read only messages with 'written_at' value greater or equal than this timestamp.
*
*
* .google.protobuf.Timestamp read_from = 4;
*/
private com.google.protobuf.SingleFieldBuilderV3<
com.google.protobuf.Timestamp, com.google.protobuf.Timestamp.Builder, com.google.protobuf.TimestampOrBuilder>
getReadFromFieldBuilder() {
if (readFromBuilder_ == null) {
readFromBuilder_ = new com.google.protobuf.SingleFieldBuilderV3<
com.google.protobuf.Timestamp, com.google.protobuf.Timestamp.Builder, com.google.protobuf.TimestampOrBuilder>(
getReadFrom(),
getParentForChildren(),
isClean());
readFrom_ = null;
}
return readFromBuilder_;
}
@java.lang.Override
public final Builder setUnknownFields(
final com.google.protobuf.UnknownFieldSet unknownFields) {
return super.setUnknownFields(unknownFields);
}
@java.lang.Override
public final Builder mergeUnknownFields(
final com.google.protobuf.UnknownFieldSet unknownFields) {
return super.mergeUnknownFields(unknownFields);
}
// @@protoc_insertion_point(builder_scope:Ydb.Topic.StreamReadMessage.InitRequest.TopicReadSettings)
}
// @@protoc_insertion_point(class_scope:Ydb.Topic.StreamReadMessage.InitRequest.TopicReadSettings)
private static final tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest.TopicReadSettings DEFAULT_INSTANCE;
static {
DEFAULT_INSTANCE = new tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest.TopicReadSettings();
}
public static tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest.TopicReadSettings getDefaultInstance() {
return DEFAULT_INSTANCE;
}
private static final com.google.protobuf.Parser
PARSER = new com.google.protobuf.AbstractParser() {
@java.lang.Override
public TopicReadSettings parsePartialFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
Builder builder = newBuilder();
try {
builder.mergeFrom(input, extensionRegistry);
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.setUnfinishedMessage(builder.buildPartial());
} catch (com.google.protobuf.UninitializedMessageException e) {
throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial());
} catch (java.io.IOException e) {
throw new com.google.protobuf.InvalidProtocolBufferException(e)
.setUnfinishedMessage(builder.buildPartial());
}
return builder.buildPartial();
}
};
public static com.google.protobuf.Parser parser() {
return PARSER;
}
@java.lang.Override
public com.google.protobuf.Parser getParserForType() {
return PARSER;
}
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest.TopicReadSettings getDefaultInstanceForType() {
return DEFAULT_INSTANCE;
}
}
public static final int TOPICS_READ_SETTINGS_FIELD_NUMBER = 1;
@SuppressWarnings("serial")
private java.util.List topicsReadSettings_;
/**
*
* Message that describes topic to read.
* Topics that will be read by this session.
*
*
* repeated .Ydb.Topic.StreamReadMessage.InitRequest.TopicReadSettings topics_read_settings = 1;
*/
@java.lang.Override
public java.util.List getTopicsReadSettingsList() {
return topicsReadSettings_;
}
/**
*
* Message that describes topic to read.
* Topics that will be read by this session.
*
*
* repeated .Ydb.Topic.StreamReadMessage.InitRequest.TopicReadSettings topics_read_settings = 1;
*/
@java.lang.Override
public java.util.List extends tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest.TopicReadSettingsOrBuilder>
getTopicsReadSettingsOrBuilderList() {
return topicsReadSettings_;
}
/**
*
* Message that describes topic to read.
* Topics that will be read by this session.
*
*
* repeated .Ydb.Topic.StreamReadMessage.InitRequest.TopicReadSettings topics_read_settings = 1;
*/
@java.lang.Override
public int getTopicsReadSettingsCount() {
return topicsReadSettings_.size();
}
/**
*
* Message that describes topic to read.
* Topics that will be read by this session.
*
*
* repeated .Ydb.Topic.StreamReadMessage.InitRequest.TopicReadSettings topics_read_settings = 1;
*/
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest.TopicReadSettings getTopicsReadSettings(int index) {
return topicsReadSettings_.get(index);
}
/**
*
* Message that describes topic to read.
* Topics that will be read by this session.
*
*
* repeated .Ydb.Topic.StreamReadMessage.InitRequest.TopicReadSettings topics_read_settings = 1;
*/
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest.TopicReadSettingsOrBuilder getTopicsReadSettingsOrBuilder(
int index) {
return topicsReadSettings_.get(index);
}
public static final int CONSUMER_FIELD_NUMBER = 2;
@SuppressWarnings("serial")
private volatile java.lang.Object consumer_ = "";
/**
*
* Path of consumer that is used for reading by this session.
*
*
* string consumer = 2;
* @return The consumer.
*/
@java.lang.Override
public java.lang.String getConsumer() {
java.lang.Object ref = consumer_;
if (ref instanceof java.lang.String) {
return (java.lang.String) ref;
} else {
com.google.protobuf.ByteString bs =
(com.google.protobuf.ByteString) ref;
java.lang.String s = bs.toStringUtf8();
consumer_ = s;
return s;
}
}
/**
*
* Path of consumer that is used for reading by this session.
*
*
* string consumer = 2;
* @return The bytes for consumer.
*/
@java.lang.Override
public com.google.protobuf.ByteString
getConsumerBytes() {
java.lang.Object ref = consumer_;
if (ref instanceof java.lang.String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
consumer_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
public static final int READER_NAME_FIELD_NUMBER = 3;
@SuppressWarnings("serial")
private volatile java.lang.Object readerName_ = "";
/**
*
* Optional name. Will be shown in debug stat.
*
*
* string reader_name = 3;
* @return The readerName.
*/
@java.lang.Override
public java.lang.String getReaderName() {
java.lang.Object ref = readerName_;
if (ref instanceof java.lang.String) {
return (java.lang.String) ref;
} else {
com.google.protobuf.ByteString bs =
(com.google.protobuf.ByteString) ref;
java.lang.String s = bs.toStringUtf8();
readerName_ = s;
return s;
}
}
/**
*
* Optional name. Will be shown in debug stat.
*
*
* string reader_name = 3;
* @return The bytes for readerName.
*/
@java.lang.Override
public com.google.protobuf.ByteString
getReaderNameBytes() {
java.lang.Object ref = readerName_;
if (ref instanceof java.lang.String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
readerName_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
public static final int DIRECT_READ_FIELD_NUMBER = 4;
private boolean directRead_ = false;
/**
*
* Direct reading from a partition node.
*
*
* bool direct_read = 4;
* @return The directRead.
*/
@java.lang.Override
public boolean getDirectRead() {
return directRead_;
}
private byte memoizedIsInitialized = -1;
@java.lang.Override
public final boolean isInitialized() {
byte isInitialized = memoizedIsInitialized;
if (isInitialized == 1) return true;
if (isInitialized == 0) return false;
memoizedIsInitialized = 1;
return true;
}
@java.lang.Override
public void writeTo(com.google.protobuf.CodedOutputStream output)
throws java.io.IOException {
for (int i = 0; i < topicsReadSettings_.size(); i++) {
output.writeMessage(1, topicsReadSettings_.get(i));
}
if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(consumer_)) {
com.google.protobuf.GeneratedMessageV3.writeString(output, 2, consumer_);
}
if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(readerName_)) {
com.google.protobuf.GeneratedMessageV3.writeString(output, 3, readerName_);
}
if (directRead_ != false) {
output.writeBool(4, directRead_);
}
getUnknownFields().writeTo(output);
}
@java.lang.Override
public int getSerializedSize() {
int size = memoizedSize;
if (size != -1) return size;
size = 0;
for (int i = 0; i < topicsReadSettings_.size(); i++) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(1, topicsReadSettings_.get(i));
}
if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(consumer_)) {
size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, consumer_);
}
if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(readerName_)) {
size += com.google.protobuf.GeneratedMessageV3.computeStringSize(3, readerName_);
}
if (directRead_ != false) {
size += com.google.protobuf.CodedOutputStream
.computeBoolSize(4, directRead_);
}
size += getUnknownFields().getSerializedSize();
memoizedSize = size;
return size;
}
@java.lang.Override
public boolean equals(final java.lang.Object obj) {
if (obj == this) {
return true;
}
if (!(obj instanceof tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest)) {
return super.equals(obj);
}
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest other = (tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest) obj;
if (!getTopicsReadSettingsList()
.equals(other.getTopicsReadSettingsList())) return false;
if (!getConsumer()
.equals(other.getConsumer())) return false;
if (!getReaderName()
.equals(other.getReaderName())) return false;
if (getDirectRead()
!= other.getDirectRead()) return false;
if (!getUnknownFields().equals(other.getUnknownFields())) return false;
return true;
}
@java.lang.Override
public int hashCode() {
if (memoizedHashCode != 0) {
return memoizedHashCode;
}
int hash = 41;
hash = (19 * hash) + getDescriptor().hashCode();
if (getTopicsReadSettingsCount() > 0) {
hash = (37 * hash) + TOPICS_READ_SETTINGS_FIELD_NUMBER;
hash = (53 * hash) + getTopicsReadSettingsList().hashCode();
}
hash = (37 * hash) + CONSUMER_FIELD_NUMBER;
hash = (53 * hash) + getConsumer().hashCode();
hash = (37 * hash) + READER_NAME_FIELD_NUMBER;
hash = (53 * hash) + getReaderName().hashCode();
hash = (37 * hash) + DIRECT_READ_FIELD_NUMBER;
hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(
getDirectRead());
hash = (29 * hash) + getUnknownFields().hashCode();
memoizedHashCode = hash;
return hash;
}
public static tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest parseFrom(
java.nio.ByteBuffer data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest parseFrom(
java.nio.ByteBuffer data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest parseFrom(
com.google.protobuf.ByteString data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest parseFrom(
com.google.protobuf.ByteString data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest parseFrom(byte[] data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest parseFrom(
byte[] data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest parseFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest parseFrom(
java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest parseDelimitedFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input);
}
public static tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest parseDelimitedFrom(
java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest parseFrom(
com.google.protobuf.CodedInputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest parseFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry);
}
@java.lang.Override
public Builder newBuilderForType() { return newBuilder(); }
public static Builder newBuilder() {
return DEFAULT_INSTANCE.toBuilder();
}
public static Builder newBuilder(tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest prototype) {
return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
}
@java.lang.Override
public Builder toBuilder() {
return this == DEFAULT_INSTANCE
? new Builder() : new Builder().mergeFrom(this);
}
@java.lang.Override
protected Builder newBuilderForType(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
Builder builder = new Builder(parent);
return builder;
}
/**
*
* Handshake request.
*
*
* Protobuf type {@code Ydb.Topic.StreamReadMessage.InitRequest}
*/
public static final class Builder extends
com.google.protobuf.GeneratedMessageV3.Builder implements
// @@protoc_insertion_point(builder_implements:Ydb.Topic.StreamReadMessage.InitRequest)
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequestOrBuilder {
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_StreamReadMessage_InitRequest_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_StreamReadMessage_InitRequest_fieldAccessorTable
.ensureFieldAccessorsInitialized(
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest.class, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest.Builder.class);
}
// Construct using tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest.newBuilder()
private Builder() {
}
private Builder(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
super(parent);
}
@java.lang.Override
public Builder clear() {
super.clear();
bitField0_ = 0;
if (topicsReadSettingsBuilder_ == null) {
topicsReadSettings_ = java.util.Collections.emptyList();
} else {
topicsReadSettings_ = null;
topicsReadSettingsBuilder_.clear();
}
bitField0_ = (bitField0_ & ~0x00000001);
consumer_ = "";
readerName_ = "";
directRead_ = false;
return this;
}
@java.lang.Override
public com.google.protobuf.Descriptors.Descriptor
getDescriptorForType() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_StreamReadMessage_InitRequest_descriptor;
}
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest getDefaultInstanceForType() {
return tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest.getDefaultInstance();
}
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest build() {
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest result = buildPartial();
if (!result.isInitialized()) {
throw newUninitializedMessageException(result);
}
return result;
}
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest buildPartial() {
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest result = new tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest(this);
buildPartialRepeatedFields(result);
if (bitField0_ != 0) { buildPartial0(result); }
onBuilt();
return result;
}
private void buildPartialRepeatedFields(tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest result) {
if (topicsReadSettingsBuilder_ == null) {
if (((bitField0_ & 0x00000001) != 0)) {
topicsReadSettings_ = java.util.Collections.unmodifiableList(topicsReadSettings_);
bitField0_ = (bitField0_ & ~0x00000001);
}
result.topicsReadSettings_ = topicsReadSettings_;
} else {
result.topicsReadSettings_ = topicsReadSettingsBuilder_.build();
}
}
private void buildPartial0(tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest result) {
int from_bitField0_ = bitField0_;
if (((from_bitField0_ & 0x00000002) != 0)) {
result.consumer_ = consumer_;
}
if (((from_bitField0_ & 0x00000004) != 0)) {
result.readerName_ = readerName_;
}
if (((from_bitField0_ & 0x00000008) != 0)) {
result.directRead_ = directRead_;
}
}
@java.lang.Override
public Builder clone() {
return super.clone();
}
@java.lang.Override
public Builder setField(
com.google.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) {
return super.setField(field, value);
}
@java.lang.Override
public Builder clearField(
com.google.protobuf.Descriptors.FieldDescriptor field) {
return super.clearField(field);
}
@java.lang.Override
public Builder clearOneof(
com.google.protobuf.Descriptors.OneofDescriptor oneof) {
return super.clearOneof(oneof);
}
@java.lang.Override
public Builder setRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
int index, java.lang.Object value) {
return super.setRepeatedField(field, index, value);
}
@java.lang.Override
public Builder addRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) {
return super.addRepeatedField(field, value);
}
@java.lang.Override
public Builder mergeFrom(com.google.protobuf.Message other) {
if (other instanceof tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest) {
return mergeFrom((tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest)other);
} else {
super.mergeFrom(other);
return this;
}
}
public Builder mergeFrom(tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest other) {
if (other == tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest.getDefaultInstance()) return this;
if (topicsReadSettingsBuilder_ == null) {
if (!other.topicsReadSettings_.isEmpty()) {
if (topicsReadSettings_.isEmpty()) {
topicsReadSettings_ = other.topicsReadSettings_;
bitField0_ = (bitField0_ & ~0x00000001);
} else {
ensureTopicsReadSettingsIsMutable();
topicsReadSettings_.addAll(other.topicsReadSettings_);
}
onChanged();
}
} else {
if (!other.topicsReadSettings_.isEmpty()) {
if (topicsReadSettingsBuilder_.isEmpty()) {
topicsReadSettingsBuilder_.dispose();
topicsReadSettingsBuilder_ = null;
topicsReadSettings_ = other.topicsReadSettings_;
bitField0_ = (bitField0_ & ~0x00000001);
topicsReadSettingsBuilder_ =
com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders ?
getTopicsReadSettingsFieldBuilder() : null;
} else {
topicsReadSettingsBuilder_.addAllMessages(other.topicsReadSettings_);
}
}
}
if (!other.getConsumer().isEmpty()) {
consumer_ = other.consumer_;
bitField0_ |= 0x00000002;
onChanged();
}
if (!other.getReaderName().isEmpty()) {
readerName_ = other.readerName_;
bitField0_ |= 0x00000004;
onChanged();
}
if (other.getDirectRead() != false) {
setDirectRead(other.getDirectRead());
}
this.mergeUnknownFields(other.getUnknownFields());
onChanged();
return this;
}
@java.lang.Override
public final boolean isInitialized() {
return true;
}
@java.lang.Override
public Builder mergeFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
if (extensionRegistry == null) {
throw new java.lang.NullPointerException();
}
try {
boolean done = false;
while (!done) {
int tag = input.readTag();
switch (tag) {
case 0:
done = true;
break;
case 10: {
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest.TopicReadSettings m =
input.readMessage(
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest.TopicReadSettings.parser(),
extensionRegistry);
if (topicsReadSettingsBuilder_ == null) {
ensureTopicsReadSettingsIsMutable();
topicsReadSettings_.add(m);
} else {
topicsReadSettingsBuilder_.addMessage(m);
}
break;
} // case 10
case 18: {
consumer_ = input.readStringRequireUtf8();
bitField0_ |= 0x00000002;
break;
} // case 18
case 26: {
readerName_ = input.readStringRequireUtf8();
bitField0_ |= 0x00000004;
break;
} // case 26
case 32: {
directRead_ = input.readBool();
bitField0_ |= 0x00000008;
break;
} // case 32
default: {
if (!super.parseUnknownField(input, extensionRegistry, tag)) {
done = true; // was an endgroup tag
}
break;
} // default:
} // switch (tag)
} // while (!done)
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.unwrapIOException();
} finally {
onChanged();
} // finally
return this;
}
private int bitField0_;
private java.util.List topicsReadSettings_ =
java.util.Collections.emptyList();
private void ensureTopicsReadSettingsIsMutable() {
if (!((bitField0_ & 0x00000001) != 0)) {
topicsReadSettings_ = new java.util.ArrayList(topicsReadSettings_);
bitField0_ |= 0x00000001;
}
}
private com.google.protobuf.RepeatedFieldBuilderV3<
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest.TopicReadSettings, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest.TopicReadSettings.Builder, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest.TopicReadSettingsOrBuilder> topicsReadSettingsBuilder_;
/**
*
* Message that describes topic to read.
* Topics that will be read by this session.
*
*
* repeated .Ydb.Topic.StreamReadMessage.InitRequest.TopicReadSettings topics_read_settings = 1;
*/
public java.util.List getTopicsReadSettingsList() {
if (topicsReadSettingsBuilder_ == null) {
return java.util.Collections.unmodifiableList(topicsReadSettings_);
} else {
return topicsReadSettingsBuilder_.getMessageList();
}
}
/**
*
* Message that describes topic to read.
* Topics that will be read by this session.
*
*
* repeated .Ydb.Topic.StreamReadMessage.InitRequest.TopicReadSettings topics_read_settings = 1;
*/
public int getTopicsReadSettingsCount() {
if (topicsReadSettingsBuilder_ == null) {
return topicsReadSettings_.size();
} else {
return topicsReadSettingsBuilder_.getCount();
}
}
/**
*
* Message that describes topic to read.
* Topics that will be read by this session.
*
*
* repeated .Ydb.Topic.StreamReadMessage.InitRequest.TopicReadSettings topics_read_settings = 1;
*/
public tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest.TopicReadSettings getTopicsReadSettings(int index) {
if (topicsReadSettingsBuilder_ == null) {
return topicsReadSettings_.get(index);
} else {
return topicsReadSettingsBuilder_.getMessage(index);
}
}
/**
*
* Message that describes topic to read.
* Topics that will be read by this session.
*
*
* repeated .Ydb.Topic.StreamReadMessage.InitRequest.TopicReadSettings topics_read_settings = 1;
*/
public Builder setTopicsReadSettings(
int index, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest.TopicReadSettings value) {
if (topicsReadSettingsBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
ensureTopicsReadSettingsIsMutable();
topicsReadSettings_.set(index, value);
onChanged();
} else {
topicsReadSettingsBuilder_.setMessage(index, value);
}
return this;
}
/**
*
* Message that describes topic to read.
* Topics that will be read by this session.
*
*
* repeated .Ydb.Topic.StreamReadMessage.InitRequest.TopicReadSettings topics_read_settings = 1;
*/
public Builder setTopicsReadSettings(
int index, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest.TopicReadSettings.Builder builderForValue) {
if (topicsReadSettingsBuilder_ == null) {
ensureTopicsReadSettingsIsMutable();
topicsReadSettings_.set(index, builderForValue.build());
onChanged();
} else {
topicsReadSettingsBuilder_.setMessage(index, builderForValue.build());
}
return this;
}
/**
*
* Message that describes topic to read.
* Topics that will be read by this session.
*
*
* repeated .Ydb.Topic.StreamReadMessage.InitRequest.TopicReadSettings topics_read_settings = 1;
*/
public Builder addTopicsReadSettings(tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest.TopicReadSettings value) {
if (topicsReadSettingsBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
ensureTopicsReadSettingsIsMutable();
topicsReadSettings_.add(value);
onChanged();
} else {
topicsReadSettingsBuilder_.addMessage(value);
}
return this;
}
/**
*
* Message that describes topic to read.
* Topics that will be read by this session.
*
*
* repeated .Ydb.Topic.StreamReadMessage.InitRequest.TopicReadSettings topics_read_settings = 1;
*/
public Builder addTopicsReadSettings(
int index, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest.TopicReadSettings value) {
if (topicsReadSettingsBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
ensureTopicsReadSettingsIsMutable();
topicsReadSettings_.add(index, value);
onChanged();
} else {
topicsReadSettingsBuilder_.addMessage(index, value);
}
return this;
}
/**
*
* Message that describes topic to read.
* Topics that will be read by this session.
*
*
* repeated .Ydb.Topic.StreamReadMessage.InitRequest.TopicReadSettings topics_read_settings = 1;
*/
public Builder addTopicsReadSettings(
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest.TopicReadSettings.Builder builderForValue) {
if (topicsReadSettingsBuilder_ == null) {
ensureTopicsReadSettingsIsMutable();
topicsReadSettings_.add(builderForValue.build());
onChanged();
} else {
topicsReadSettingsBuilder_.addMessage(builderForValue.build());
}
return this;
}
/**
*
* Message that describes topic to read.
* Topics that will be read by this session.
*
*
* repeated .Ydb.Topic.StreamReadMessage.InitRequest.TopicReadSettings topics_read_settings = 1;
*/
public Builder addTopicsReadSettings(
int index, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest.TopicReadSettings.Builder builderForValue) {
if (topicsReadSettingsBuilder_ == null) {
ensureTopicsReadSettingsIsMutable();
topicsReadSettings_.add(index, builderForValue.build());
onChanged();
} else {
topicsReadSettingsBuilder_.addMessage(index, builderForValue.build());
}
return this;
}
/**
*
* Message that describes topic to read.
* Topics that will be read by this session.
*
*
* repeated .Ydb.Topic.StreamReadMessage.InitRequest.TopicReadSettings topics_read_settings = 1;
*/
public Builder addAllTopicsReadSettings(
java.lang.Iterable extends tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest.TopicReadSettings> values) {
if (topicsReadSettingsBuilder_ == null) {
ensureTopicsReadSettingsIsMutable();
com.google.protobuf.AbstractMessageLite.Builder.addAll(
values, topicsReadSettings_);
onChanged();
} else {
topicsReadSettingsBuilder_.addAllMessages(values);
}
return this;
}
/**
*
* Message that describes topic to read.
* Topics that will be read by this session.
*
*
* repeated .Ydb.Topic.StreamReadMessage.InitRequest.TopicReadSettings topics_read_settings = 1;
*/
public Builder clearTopicsReadSettings() {
if (topicsReadSettingsBuilder_ == null) {
topicsReadSettings_ = java.util.Collections.emptyList();
bitField0_ = (bitField0_ & ~0x00000001);
onChanged();
} else {
topicsReadSettingsBuilder_.clear();
}
return this;
}
/**
*
* Message that describes topic to read.
* Topics that will be read by this session.
*
*
* repeated .Ydb.Topic.StreamReadMessage.InitRequest.TopicReadSettings topics_read_settings = 1;
*/
public Builder removeTopicsReadSettings(int index) {
if (topicsReadSettingsBuilder_ == null) {
ensureTopicsReadSettingsIsMutable();
topicsReadSettings_.remove(index);
onChanged();
} else {
topicsReadSettingsBuilder_.remove(index);
}
return this;
}
/**
*
* Message that describes topic to read.
* Topics that will be read by this session.
*
*
* repeated .Ydb.Topic.StreamReadMessage.InitRequest.TopicReadSettings topics_read_settings = 1;
*/
public tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest.TopicReadSettings.Builder getTopicsReadSettingsBuilder(
int index) {
return getTopicsReadSettingsFieldBuilder().getBuilder(index);
}
/**
*
* Message that describes topic to read.
* Topics that will be read by this session.
*
*
* repeated .Ydb.Topic.StreamReadMessage.InitRequest.TopicReadSettings topics_read_settings = 1;
*/
public tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest.TopicReadSettingsOrBuilder getTopicsReadSettingsOrBuilder(
int index) {
if (topicsReadSettingsBuilder_ == null) {
return topicsReadSettings_.get(index); } else {
return topicsReadSettingsBuilder_.getMessageOrBuilder(index);
}
}
/**
*
* Message that describes topic to read.
* Topics that will be read by this session.
*
*
* repeated .Ydb.Topic.StreamReadMessage.InitRequest.TopicReadSettings topics_read_settings = 1;
*/
public java.util.List extends tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest.TopicReadSettingsOrBuilder>
getTopicsReadSettingsOrBuilderList() {
if (topicsReadSettingsBuilder_ != null) {
return topicsReadSettingsBuilder_.getMessageOrBuilderList();
} else {
return java.util.Collections.unmodifiableList(topicsReadSettings_);
}
}
/**
*
* Message that describes topic to read.
* Topics that will be read by this session.
*
*
* repeated .Ydb.Topic.StreamReadMessage.InitRequest.TopicReadSettings topics_read_settings = 1;
*/
public tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest.TopicReadSettings.Builder addTopicsReadSettingsBuilder() {
return getTopicsReadSettingsFieldBuilder().addBuilder(
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest.TopicReadSettings.getDefaultInstance());
}
/**
*
* Message that describes topic to read.
* Topics that will be read by this session.
*
*
* repeated .Ydb.Topic.StreamReadMessage.InitRequest.TopicReadSettings topics_read_settings = 1;
*/
public tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest.TopicReadSettings.Builder addTopicsReadSettingsBuilder(
int index) {
return getTopicsReadSettingsFieldBuilder().addBuilder(
index, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest.TopicReadSettings.getDefaultInstance());
}
/**
*
* Message that describes topic to read.
* Topics that will be read by this session.
*
*
* repeated .Ydb.Topic.StreamReadMessage.InitRequest.TopicReadSettings topics_read_settings = 1;
*/
public java.util.List
getTopicsReadSettingsBuilderList() {
return getTopicsReadSettingsFieldBuilder().getBuilderList();
}
private com.google.protobuf.RepeatedFieldBuilderV3<
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest.TopicReadSettings, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest.TopicReadSettings.Builder, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest.TopicReadSettingsOrBuilder>
getTopicsReadSettingsFieldBuilder() {
if (topicsReadSettingsBuilder_ == null) {
topicsReadSettingsBuilder_ = new com.google.protobuf.RepeatedFieldBuilderV3<
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest.TopicReadSettings, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest.TopicReadSettings.Builder, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest.TopicReadSettingsOrBuilder>(
topicsReadSettings_,
((bitField0_ & 0x00000001) != 0),
getParentForChildren(),
isClean());
topicsReadSettings_ = null;
}
return topicsReadSettingsBuilder_;
}
private java.lang.Object consumer_ = "";
/**
*
* Path of consumer that is used for reading by this session.
*
*
* string consumer = 2;
* @return The consumer.
*/
public java.lang.String getConsumer() {
java.lang.Object ref = consumer_;
if (!(ref instanceof java.lang.String)) {
com.google.protobuf.ByteString bs =
(com.google.protobuf.ByteString) ref;
java.lang.String s = bs.toStringUtf8();
consumer_ = s;
return s;
} else {
return (java.lang.String) ref;
}
}
/**
*
* Path of consumer that is used for reading by this session.
*
*
* string consumer = 2;
* @return The bytes for consumer.
*/
public com.google.protobuf.ByteString
getConsumerBytes() {
java.lang.Object ref = consumer_;
if (ref instanceof String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
consumer_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
/**
*
* Path of consumer that is used for reading by this session.
*
*
* string consumer = 2;
* @param value The consumer to set.
* @return This builder for chaining.
*/
public Builder setConsumer(
java.lang.String value) {
if (value == null) { throw new NullPointerException(); }
consumer_ = value;
bitField0_ |= 0x00000002;
onChanged();
return this;
}
/**
*
* Path of consumer that is used for reading by this session.
*
*
* string consumer = 2;
* @return This builder for chaining.
*/
public Builder clearConsumer() {
consumer_ = getDefaultInstance().getConsumer();
bitField0_ = (bitField0_ & ~0x00000002);
onChanged();
return this;
}
/**
*
* Path of consumer that is used for reading by this session.
*
*
* string consumer = 2;
* @param value The bytes for consumer to set.
* @return This builder for chaining.
*/
public Builder setConsumerBytes(
com.google.protobuf.ByteString value) {
if (value == null) { throw new NullPointerException(); }
checkByteStringIsUtf8(value);
consumer_ = value;
bitField0_ |= 0x00000002;
onChanged();
return this;
}
private java.lang.Object readerName_ = "";
/**
*
* Optional name. Will be shown in debug stat.
*
*
* string reader_name = 3;
* @return The readerName.
*/
public java.lang.String getReaderName() {
java.lang.Object ref = readerName_;
if (!(ref instanceof java.lang.String)) {
com.google.protobuf.ByteString bs =
(com.google.protobuf.ByteString) ref;
java.lang.String s = bs.toStringUtf8();
readerName_ = s;
return s;
} else {
return (java.lang.String) ref;
}
}
/**
*
* Optional name. Will be shown in debug stat.
*
*
* string reader_name = 3;
* @return The bytes for readerName.
*/
public com.google.protobuf.ByteString
getReaderNameBytes() {
java.lang.Object ref = readerName_;
if (ref instanceof String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
readerName_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
/**
*
* Optional name. Will be shown in debug stat.
*
*
* string reader_name = 3;
* @param value The readerName to set.
* @return This builder for chaining.
*/
public Builder setReaderName(
java.lang.String value) {
if (value == null) { throw new NullPointerException(); }
readerName_ = value;
bitField0_ |= 0x00000004;
onChanged();
return this;
}
/**
*
* Optional name. Will be shown in debug stat.
*
*
* string reader_name = 3;
* @return This builder for chaining.
*/
public Builder clearReaderName() {
readerName_ = getDefaultInstance().getReaderName();
bitField0_ = (bitField0_ & ~0x00000004);
onChanged();
return this;
}
/**
*
* Optional name. Will be shown in debug stat.
*
*
* string reader_name = 3;
* @param value The bytes for readerName to set.
* @return This builder for chaining.
*/
public Builder setReaderNameBytes(
com.google.protobuf.ByteString value) {
if (value == null) { throw new NullPointerException(); }
checkByteStringIsUtf8(value);
readerName_ = value;
bitField0_ |= 0x00000004;
onChanged();
return this;
}
private boolean directRead_ ;
/**
*
* Direct reading from a partition node.
*
*
* bool direct_read = 4;
* @return The directRead.
*/
@java.lang.Override
public boolean getDirectRead() {
return directRead_;
}
/**
*
* Direct reading from a partition node.
*
*
* bool direct_read = 4;
* @param value The directRead to set.
* @return This builder for chaining.
*/
public Builder setDirectRead(boolean value) {
directRead_ = value;
bitField0_ |= 0x00000008;
onChanged();
return this;
}
/**
*
* Direct reading from a partition node.
*
*
* bool direct_read = 4;
* @return This builder for chaining.
*/
public Builder clearDirectRead() {
bitField0_ = (bitField0_ & ~0x00000008);
directRead_ = false;
onChanged();
return this;
}
@java.lang.Override
public final Builder setUnknownFields(
final com.google.protobuf.UnknownFieldSet unknownFields) {
return super.setUnknownFields(unknownFields);
}
@java.lang.Override
public final Builder mergeUnknownFields(
final com.google.protobuf.UnknownFieldSet unknownFields) {
return super.mergeUnknownFields(unknownFields);
}
// @@protoc_insertion_point(builder_scope:Ydb.Topic.StreamReadMessage.InitRequest)
}
// @@protoc_insertion_point(class_scope:Ydb.Topic.StreamReadMessage.InitRequest)
private static final tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest DEFAULT_INSTANCE;
static {
DEFAULT_INSTANCE = new tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest();
}
public static tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest getDefaultInstance() {
return DEFAULT_INSTANCE;
}
private static final com.google.protobuf.Parser
PARSER = new com.google.protobuf.AbstractParser() {
@java.lang.Override
public InitRequest parsePartialFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
Builder builder = newBuilder();
try {
builder.mergeFrom(input, extensionRegistry);
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.setUnfinishedMessage(builder.buildPartial());
} catch (com.google.protobuf.UninitializedMessageException e) {
throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial());
} catch (java.io.IOException e) {
throw new com.google.protobuf.InvalidProtocolBufferException(e)
.setUnfinishedMessage(builder.buildPartial());
}
return builder.buildPartial();
}
};
public static com.google.protobuf.Parser parser() {
return PARSER;
}
@java.lang.Override
public com.google.protobuf.Parser getParserForType() {
return PARSER;
}
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitRequest getDefaultInstanceForType() {
return DEFAULT_INSTANCE;
}
}
public interface InitResponseOrBuilder extends
// @@protoc_insertion_point(interface_extends:Ydb.Topic.StreamReadMessage.InitResponse)
com.google.protobuf.MessageOrBuilder {
/**
*
* Read session identifier.
*
*
* string session_id = 1;
* @return The sessionId.
*/
java.lang.String getSessionId();
/**
*
* Read session identifier.
*
*
* string session_id = 1;
* @return The bytes for sessionId.
*/
com.google.protobuf.ByteString
getSessionIdBytes();
}
/**
*
* Handshake response.
*
*
* Protobuf type {@code Ydb.Topic.StreamReadMessage.InitResponse}
*/
public static final class InitResponse extends
com.google.protobuf.GeneratedMessageV3 implements
// @@protoc_insertion_point(message_implements:Ydb.Topic.StreamReadMessage.InitResponse)
InitResponseOrBuilder {
private static final long serialVersionUID = 0L;
// Use InitResponse.newBuilder() to construct.
private InitResponse(com.google.protobuf.GeneratedMessageV3.Builder> builder) {
super(builder);
}
private InitResponse() {
sessionId_ = "";
}
@java.lang.Override
@SuppressWarnings({"unused"})
protected java.lang.Object newInstance(
UnusedPrivateParameter unused) {
return new InitResponse();
}
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_StreamReadMessage_InitResponse_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_StreamReadMessage_InitResponse_fieldAccessorTable
.ensureFieldAccessorsInitialized(
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitResponse.class, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitResponse.Builder.class);
}
public static final int SESSION_ID_FIELD_NUMBER = 1;
@SuppressWarnings("serial")
private volatile java.lang.Object sessionId_ = "";
/**
*
* Read session identifier.
*
*
* string session_id = 1;
* @return The sessionId.
*/
@java.lang.Override
public java.lang.String getSessionId() {
java.lang.Object ref = sessionId_;
if (ref instanceof java.lang.String) {
return (java.lang.String) ref;
} else {
com.google.protobuf.ByteString bs =
(com.google.protobuf.ByteString) ref;
java.lang.String s = bs.toStringUtf8();
sessionId_ = s;
return s;
}
}
/**
*
* Read session identifier.
*
*
* string session_id = 1;
* @return The bytes for sessionId.
*/
@java.lang.Override
public com.google.protobuf.ByteString
getSessionIdBytes() {
java.lang.Object ref = sessionId_;
if (ref instanceof java.lang.String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
sessionId_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
private byte memoizedIsInitialized = -1;
@java.lang.Override
public final boolean isInitialized() {
byte isInitialized = memoizedIsInitialized;
if (isInitialized == 1) return true;
if (isInitialized == 0) return false;
memoizedIsInitialized = 1;
return true;
}
@java.lang.Override
public void writeTo(com.google.protobuf.CodedOutputStream output)
throws java.io.IOException {
if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(sessionId_)) {
com.google.protobuf.GeneratedMessageV3.writeString(output, 1, sessionId_);
}
getUnknownFields().writeTo(output);
}
@java.lang.Override
public int getSerializedSize() {
int size = memoizedSize;
if (size != -1) return size;
size = 0;
if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(sessionId_)) {
size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, sessionId_);
}
size += getUnknownFields().getSerializedSize();
memoizedSize = size;
return size;
}
@java.lang.Override
public boolean equals(final java.lang.Object obj) {
if (obj == this) {
return true;
}
if (!(obj instanceof tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitResponse)) {
return super.equals(obj);
}
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitResponse other = (tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitResponse) obj;
if (!getSessionId()
.equals(other.getSessionId())) return false;
if (!getUnknownFields().equals(other.getUnknownFields())) return false;
return true;
}
@java.lang.Override
public int hashCode() {
if (memoizedHashCode != 0) {
return memoizedHashCode;
}
int hash = 41;
hash = (19 * hash) + getDescriptor().hashCode();
hash = (37 * hash) + SESSION_ID_FIELD_NUMBER;
hash = (53 * hash) + getSessionId().hashCode();
hash = (29 * hash) + getUnknownFields().hashCode();
memoizedHashCode = hash;
return hash;
}
public static tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitResponse parseFrom(
java.nio.ByteBuffer data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitResponse parseFrom(
java.nio.ByteBuffer data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitResponse parseFrom(
com.google.protobuf.ByteString data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitResponse parseFrom(
com.google.protobuf.ByteString data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitResponse parseFrom(byte[] data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitResponse parseFrom(
byte[] data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitResponse parseFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitResponse parseFrom(
java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitResponse parseDelimitedFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input);
}
public static tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitResponse parseDelimitedFrom(
java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitResponse parseFrom(
com.google.protobuf.CodedInputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitResponse parseFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry);
}
@java.lang.Override
public Builder newBuilderForType() { return newBuilder(); }
public static Builder newBuilder() {
return DEFAULT_INSTANCE.toBuilder();
}
public static Builder newBuilder(tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitResponse prototype) {
return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
}
@java.lang.Override
public Builder toBuilder() {
return this == DEFAULT_INSTANCE
? new Builder() : new Builder().mergeFrom(this);
}
@java.lang.Override
protected Builder newBuilderForType(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
Builder builder = new Builder(parent);
return builder;
}
/**
*
* Handshake response.
*
*
* Protobuf type {@code Ydb.Topic.StreamReadMessage.InitResponse}
*/
public static final class Builder extends
com.google.protobuf.GeneratedMessageV3.Builder implements
// @@protoc_insertion_point(builder_implements:Ydb.Topic.StreamReadMessage.InitResponse)
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitResponseOrBuilder {
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_StreamReadMessage_InitResponse_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_StreamReadMessage_InitResponse_fieldAccessorTable
.ensureFieldAccessorsInitialized(
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitResponse.class, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitResponse.Builder.class);
}
// Construct using tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitResponse.newBuilder()
private Builder() {
}
private Builder(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
super(parent);
}
@java.lang.Override
public Builder clear() {
super.clear();
bitField0_ = 0;
sessionId_ = "";
return this;
}
@java.lang.Override
public com.google.protobuf.Descriptors.Descriptor
getDescriptorForType() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_StreamReadMessage_InitResponse_descriptor;
}
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitResponse getDefaultInstanceForType() {
return tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitResponse.getDefaultInstance();
}
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitResponse build() {
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitResponse result = buildPartial();
if (!result.isInitialized()) {
throw newUninitializedMessageException(result);
}
return result;
}
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitResponse buildPartial() {
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitResponse result = new tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitResponse(this);
if (bitField0_ != 0) { buildPartial0(result); }
onBuilt();
return result;
}
private void buildPartial0(tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitResponse result) {
int from_bitField0_ = bitField0_;
if (((from_bitField0_ & 0x00000001) != 0)) {
result.sessionId_ = sessionId_;
}
}
@java.lang.Override
public Builder clone() {
return super.clone();
}
@java.lang.Override
public Builder setField(
com.google.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) {
return super.setField(field, value);
}
@java.lang.Override
public Builder clearField(
com.google.protobuf.Descriptors.FieldDescriptor field) {
return super.clearField(field);
}
@java.lang.Override
public Builder clearOneof(
com.google.protobuf.Descriptors.OneofDescriptor oneof) {
return super.clearOneof(oneof);
}
@java.lang.Override
public Builder setRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
int index, java.lang.Object value) {
return super.setRepeatedField(field, index, value);
}
@java.lang.Override
public Builder addRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) {
return super.addRepeatedField(field, value);
}
@java.lang.Override
public Builder mergeFrom(com.google.protobuf.Message other) {
if (other instanceof tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitResponse) {
return mergeFrom((tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitResponse)other);
} else {
super.mergeFrom(other);
return this;
}
}
public Builder mergeFrom(tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitResponse other) {
if (other == tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitResponse.getDefaultInstance()) return this;
if (!other.getSessionId().isEmpty()) {
sessionId_ = other.sessionId_;
bitField0_ |= 0x00000001;
onChanged();
}
this.mergeUnknownFields(other.getUnknownFields());
onChanged();
return this;
}
@java.lang.Override
public final boolean isInitialized() {
return true;
}
@java.lang.Override
public Builder mergeFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
if (extensionRegistry == null) {
throw new java.lang.NullPointerException();
}
try {
boolean done = false;
while (!done) {
int tag = input.readTag();
switch (tag) {
case 0:
done = true;
break;
case 10: {
sessionId_ = input.readStringRequireUtf8();
bitField0_ |= 0x00000001;
break;
} // case 10
default: {
if (!super.parseUnknownField(input, extensionRegistry, tag)) {
done = true; // was an endgroup tag
}
break;
} // default:
} // switch (tag)
} // while (!done)
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.unwrapIOException();
} finally {
onChanged();
} // finally
return this;
}
private int bitField0_;
private java.lang.Object sessionId_ = "";
/**
*
* Read session identifier.
*
*
* string session_id = 1;
* @return The sessionId.
*/
public java.lang.String getSessionId() {
java.lang.Object ref = sessionId_;
if (!(ref instanceof java.lang.String)) {
com.google.protobuf.ByteString bs =
(com.google.protobuf.ByteString) ref;
java.lang.String s = bs.toStringUtf8();
sessionId_ = s;
return s;
} else {
return (java.lang.String) ref;
}
}
/**
*
* Read session identifier.
*
*
* string session_id = 1;
* @return The bytes for sessionId.
*/
public com.google.protobuf.ByteString
getSessionIdBytes() {
java.lang.Object ref = sessionId_;
if (ref instanceof String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
sessionId_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
/**
*
* Read session identifier.
*
*
* string session_id = 1;
* @param value The sessionId to set.
* @return This builder for chaining.
*/
public Builder setSessionId(
java.lang.String value) {
if (value == null) { throw new NullPointerException(); }
sessionId_ = value;
bitField0_ |= 0x00000001;
onChanged();
return this;
}
/**
*
* Read session identifier.
*
*
* string session_id = 1;
* @return This builder for chaining.
*/
public Builder clearSessionId() {
sessionId_ = getDefaultInstance().getSessionId();
bitField0_ = (bitField0_ & ~0x00000001);
onChanged();
return this;
}
/**
*
* Read session identifier.
*
*
* string session_id = 1;
* @param value The bytes for sessionId to set.
* @return This builder for chaining.
*/
public Builder setSessionIdBytes(
com.google.protobuf.ByteString value) {
if (value == null) { throw new NullPointerException(); }
checkByteStringIsUtf8(value);
sessionId_ = value;
bitField0_ |= 0x00000001;
onChanged();
return this;
}
@java.lang.Override
public final Builder setUnknownFields(
final com.google.protobuf.UnknownFieldSet unknownFields) {
return super.setUnknownFields(unknownFields);
}
@java.lang.Override
public final Builder mergeUnknownFields(
final com.google.protobuf.UnknownFieldSet unknownFields) {
return super.mergeUnknownFields(unknownFields);
}
// @@protoc_insertion_point(builder_scope:Ydb.Topic.StreamReadMessage.InitResponse)
}
// @@protoc_insertion_point(class_scope:Ydb.Topic.StreamReadMessage.InitResponse)
private static final tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitResponse DEFAULT_INSTANCE;
static {
DEFAULT_INSTANCE = new tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitResponse();
}
public static tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitResponse getDefaultInstance() {
return DEFAULT_INSTANCE;
}
private static final com.google.protobuf.Parser
PARSER = new com.google.protobuf.AbstractParser() {
@java.lang.Override
public InitResponse parsePartialFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
Builder builder = newBuilder();
try {
builder.mergeFrom(input, extensionRegistry);
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.setUnfinishedMessage(builder.buildPartial());
} catch (com.google.protobuf.UninitializedMessageException e) {
throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial());
} catch (java.io.IOException e) {
throw new com.google.protobuf.InvalidProtocolBufferException(e)
.setUnfinishedMessage(builder.buildPartial());
}
return builder.buildPartial();
}
};
public static com.google.protobuf.Parser parser() {
return PARSER;
}
@java.lang.Override
public com.google.protobuf.Parser getParserForType() {
return PARSER;
}
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamReadMessage.InitResponse getDefaultInstanceForType() {
return DEFAULT_INSTANCE;
}
}
public interface ReadRequestOrBuilder extends
// @@protoc_insertion_point(interface_extends:Ydb.Topic.StreamReadMessage.ReadRequest)
com.google.protobuf.MessageOrBuilder {
/**
*
* Server and client each keep track of total bytes size of all ReadResponses.
* When client is ready to receive N more bytes in responses (to increment possible total by N),
* it sends a ReadRequest with bytes_size = N.
* bytes_size value must be positive.
* So in expression 'A = (sum of bytes_size in all ReadRequests) - (sum of bytes_size in all ReadResponses)'
* server will keep A (available size for responses) non-negative.
* But there is an exception. If server receives ReadRequest, and the first message in response exceeds A -
* then it will still be delivered, and A will become negative until enough additional ReadRequests.
*
* Example:
* 1) Let client have 200 bytes buffer. It sends ReadRequest with bytes_size = 200;
* 2) Server may return one ReadResponse with bytes_size = 70 and than another 80 bytes response;
* now client buffer has 50 free bytes, server is free to send up to 50 bytes in responses.
* 3) Client processes 100 bytes from buffer, now buffer free space is 150 bytes,
* so client sends ReadRequest with bytes_size = 100;
* 4) Server is free to send up to 50 + 100 = 150 bytes. But the next read message is too big,
* and it sends 160 bytes ReadResponse.
* 5) Let's assume client somehow processes it, and its 200 bytes buffer is free again.
* It should account for excess 10 bytes and send ReadRequest with bytes_size = 210.
*
*
* int64 bytes_size = 1;
* @return The bytesSize.
*/
long getBytesSize();
}
/**
*
* Message that represents client readiness for receiving more data.
*
*
* Protobuf type {@code Ydb.Topic.StreamReadMessage.ReadRequest}
*/
public static final class ReadRequest extends
com.google.protobuf.GeneratedMessageV3 implements
// @@protoc_insertion_point(message_implements:Ydb.Topic.StreamReadMessage.ReadRequest)
ReadRequestOrBuilder {
private static final long serialVersionUID = 0L;
// Use ReadRequest.newBuilder() to construct.
private ReadRequest(com.google.protobuf.GeneratedMessageV3.Builder> builder) {
super(builder);
}
private ReadRequest() {
}
@java.lang.Override
@SuppressWarnings({"unused"})
protected java.lang.Object newInstance(
UnusedPrivateParameter unused) {
return new ReadRequest();
}
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_StreamReadMessage_ReadRequest_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_StreamReadMessage_ReadRequest_fieldAccessorTable
.ensureFieldAccessorsInitialized(
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadRequest.class, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadRequest.Builder.class);
}
public static final int BYTES_SIZE_FIELD_NUMBER = 1;
private long bytesSize_ = 0L;
/**
*
* Server and client each keep track of total bytes size of all ReadResponses.
* When client is ready to receive N more bytes in responses (to increment possible total by N),
* it sends a ReadRequest with bytes_size = N.
* bytes_size value must be positive.
* So in expression 'A = (sum of bytes_size in all ReadRequests) - (sum of bytes_size in all ReadResponses)'
* server will keep A (available size for responses) non-negative.
* But there is an exception. If server receives ReadRequest, and the first message in response exceeds A -
* then it will still be delivered, and A will become negative until enough additional ReadRequests.
*
* Example:
* 1) Let client have 200 bytes buffer. It sends ReadRequest with bytes_size = 200;
* 2) Server may return one ReadResponse with bytes_size = 70 and than another 80 bytes response;
* now client buffer has 50 free bytes, server is free to send up to 50 bytes in responses.
* 3) Client processes 100 bytes from buffer, now buffer free space is 150 bytes,
* so client sends ReadRequest with bytes_size = 100;
* 4) Server is free to send up to 50 + 100 = 150 bytes. But the next read message is too big,
* and it sends 160 bytes ReadResponse.
* 5) Let's assume client somehow processes it, and its 200 bytes buffer is free again.
* It should account for excess 10 bytes and send ReadRequest with bytes_size = 210.
*
*
* int64 bytes_size = 1;
* @return The bytesSize.
*/
@java.lang.Override
public long getBytesSize() {
return bytesSize_;
}
private byte memoizedIsInitialized = -1;
@java.lang.Override
public final boolean isInitialized() {
byte isInitialized = memoizedIsInitialized;
if (isInitialized == 1) return true;
if (isInitialized == 0) return false;
memoizedIsInitialized = 1;
return true;
}
@java.lang.Override
public void writeTo(com.google.protobuf.CodedOutputStream output)
throws java.io.IOException {
if (bytesSize_ != 0L) {
output.writeInt64(1, bytesSize_);
}
getUnknownFields().writeTo(output);
}
@java.lang.Override
public int getSerializedSize() {
int size = memoizedSize;
if (size != -1) return size;
size = 0;
if (bytesSize_ != 0L) {
size += com.google.protobuf.CodedOutputStream
.computeInt64Size(1, bytesSize_);
}
size += getUnknownFields().getSerializedSize();
memoizedSize = size;
return size;
}
@java.lang.Override
public boolean equals(final java.lang.Object obj) {
if (obj == this) {
return true;
}
if (!(obj instanceof tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadRequest)) {
return super.equals(obj);
}
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadRequest other = (tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadRequest) obj;
if (getBytesSize()
!= other.getBytesSize()) return false;
if (!getUnknownFields().equals(other.getUnknownFields())) return false;
return true;
}
@java.lang.Override
public int hashCode() {
if (memoizedHashCode != 0) {
return memoizedHashCode;
}
int hash = 41;
hash = (19 * hash) + getDescriptor().hashCode();
hash = (37 * hash) + BYTES_SIZE_FIELD_NUMBER;
hash = (53 * hash) + com.google.protobuf.Internal.hashLong(
getBytesSize());
hash = (29 * hash) + getUnknownFields().hashCode();
memoizedHashCode = hash;
return hash;
}
public static tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadRequest parseFrom(
java.nio.ByteBuffer data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadRequest parseFrom(
java.nio.ByteBuffer data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadRequest parseFrom(
com.google.protobuf.ByteString data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadRequest parseFrom(
com.google.protobuf.ByteString data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadRequest parseFrom(byte[] data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadRequest parseFrom(
byte[] data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadRequest parseFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadRequest parseFrom(
java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadRequest parseDelimitedFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input);
}
public static tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadRequest parseDelimitedFrom(
java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadRequest parseFrom(
com.google.protobuf.CodedInputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadRequest parseFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry);
}
@java.lang.Override
public Builder newBuilderForType() { return newBuilder(); }
public static Builder newBuilder() {
return DEFAULT_INSTANCE.toBuilder();
}
public static Builder newBuilder(tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadRequest prototype) {
return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
}
@java.lang.Override
public Builder toBuilder() {
return this == DEFAULT_INSTANCE
? new Builder() : new Builder().mergeFrom(this);
}
@java.lang.Override
protected Builder newBuilderForType(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
Builder builder = new Builder(parent);
return builder;
}
/**
*
* Message that represents client readiness for receiving more data.
*
*
* Protobuf type {@code Ydb.Topic.StreamReadMessage.ReadRequest}
*/
public static final class Builder extends
com.google.protobuf.GeneratedMessageV3.Builder implements
// @@protoc_insertion_point(builder_implements:Ydb.Topic.StreamReadMessage.ReadRequest)
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadRequestOrBuilder {
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_StreamReadMessage_ReadRequest_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_StreamReadMessage_ReadRequest_fieldAccessorTable
.ensureFieldAccessorsInitialized(
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadRequest.class, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadRequest.Builder.class);
}
// Construct using tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadRequest.newBuilder()
private Builder() {
}
private Builder(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
super(parent);
}
@java.lang.Override
public Builder clear() {
super.clear();
bitField0_ = 0;
bytesSize_ = 0L;
return this;
}
@java.lang.Override
public com.google.protobuf.Descriptors.Descriptor
getDescriptorForType() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_StreamReadMessage_ReadRequest_descriptor;
}
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadRequest getDefaultInstanceForType() {
return tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadRequest.getDefaultInstance();
}
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadRequest build() {
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadRequest result = buildPartial();
if (!result.isInitialized()) {
throw newUninitializedMessageException(result);
}
return result;
}
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadRequest buildPartial() {
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadRequest result = new tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadRequest(this);
if (bitField0_ != 0) { buildPartial0(result); }
onBuilt();
return result;
}
private void buildPartial0(tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadRequest result) {
int from_bitField0_ = bitField0_;
if (((from_bitField0_ & 0x00000001) != 0)) {
result.bytesSize_ = bytesSize_;
}
}
@java.lang.Override
public Builder clone() {
return super.clone();
}
@java.lang.Override
public Builder setField(
com.google.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) {
return super.setField(field, value);
}
@java.lang.Override
public Builder clearField(
com.google.protobuf.Descriptors.FieldDescriptor field) {
return super.clearField(field);
}
@java.lang.Override
public Builder clearOneof(
com.google.protobuf.Descriptors.OneofDescriptor oneof) {
return super.clearOneof(oneof);
}
@java.lang.Override
public Builder setRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
int index, java.lang.Object value) {
return super.setRepeatedField(field, index, value);
}
@java.lang.Override
public Builder addRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) {
return super.addRepeatedField(field, value);
}
@java.lang.Override
public Builder mergeFrom(com.google.protobuf.Message other) {
if (other instanceof tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadRequest) {
return mergeFrom((tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadRequest)other);
} else {
super.mergeFrom(other);
return this;
}
}
public Builder mergeFrom(tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadRequest other) {
if (other == tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadRequest.getDefaultInstance()) return this;
if (other.getBytesSize() != 0L) {
setBytesSize(other.getBytesSize());
}
this.mergeUnknownFields(other.getUnknownFields());
onChanged();
return this;
}
@java.lang.Override
public final boolean isInitialized() {
return true;
}
@java.lang.Override
public Builder mergeFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
if (extensionRegistry == null) {
throw new java.lang.NullPointerException();
}
try {
boolean done = false;
while (!done) {
int tag = input.readTag();
switch (tag) {
case 0:
done = true;
break;
case 8: {
bytesSize_ = input.readInt64();
bitField0_ |= 0x00000001;
break;
} // case 8
default: {
if (!super.parseUnknownField(input, extensionRegistry, tag)) {
done = true; // was an endgroup tag
}
break;
} // default:
} // switch (tag)
} // while (!done)
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.unwrapIOException();
} finally {
onChanged();
} // finally
return this;
}
private int bitField0_;
private long bytesSize_ ;
/**
*
* Server and client each keep track of total bytes size of all ReadResponses.
* When client is ready to receive N more bytes in responses (to increment possible total by N),
* it sends a ReadRequest with bytes_size = N.
* bytes_size value must be positive.
* So in expression 'A = (sum of bytes_size in all ReadRequests) - (sum of bytes_size in all ReadResponses)'
* server will keep A (available size for responses) non-negative.
* But there is an exception. If server receives ReadRequest, and the first message in response exceeds A -
* then it will still be delivered, and A will become negative until enough additional ReadRequests.
*
* Example:
* 1) Let client have 200 bytes buffer. It sends ReadRequest with bytes_size = 200;
* 2) Server may return one ReadResponse with bytes_size = 70 and than another 80 bytes response;
* now client buffer has 50 free bytes, server is free to send up to 50 bytes in responses.
* 3) Client processes 100 bytes from buffer, now buffer free space is 150 bytes,
* so client sends ReadRequest with bytes_size = 100;
* 4) Server is free to send up to 50 + 100 = 150 bytes. But the next read message is too big,
* and it sends 160 bytes ReadResponse.
* 5) Let's assume client somehow processes it, and its 200 bytes buffer is free again.
* It should account for excess 10 bytes and send ReadRequest with bytes_size = 210.
*
*
* int64 bytes_size = 1;
* @return The bytesSize.
*/
@java.lang.Override
public long getBytesSize() {
return bytesSize_;
}
/**
*
* Server and client each keep track of total bytes size of all ReadResponses.
* When client is ready to receive N more bytes in responses (to increment possible total by N),
* it sends a ReadRequest with bytes_size = N.
* bytes_size value must be positive.
* So in expression 'A = (sum of bytes_size in all ReadRequests) - (sum of bytes_size in all ReadResponses)'
* server will keep A (available size for responses) non-negative.
* But there is an exception. If server receives ReadRequest, and the first message in response exceeds A -
* then it will still be delivered, and A will become negative until enough additional ReadRequests.
*
* Example:
* 1) Let client have 200 bytes buffer. It sends ReadRequest with bytes_size = 200;
* 2) Server may return one ReadResponse with bytes_size = 70 and than another 80 bytes response;
* now client buffer has 50 free bytes, server is free to send up to 50 bytes in responses.
* 3) Client processes 100 bytes from buffer, now buffer free space is 150 bytes,
* so client sends ReadRequest with bytes_size = 100;
* 4) Server is free to send up to 50 + 100 = 150 bytes. But the next read message is too big,
* and it sends 160 bytes ReadResponse.
* 5) Let's assume client somehow processes it, and its 200 bytes buffer is free again.
* It should account for excess 10 bytes and send ReadRequest with bytes_size = 210.
*
*
* int64 bytes_size = 1;
* @param value The bytesSize to set.
* @return This builder for chaining.
*/
public Builder setBytesSize(long value) {
bytesSize_ = value;
bitField0_ |= 0x00000001;
onChanged();
return this;
}
/**
*
* Server and client each keep track of total bytes size of all ReadResponses.
* When client is ready to receive N more bytes in responses (to increment possible total by N),
* it sends a ReadRequest with bytes_size = N.
* bytes_size value must be positive.
* So in expression 'A = (sum of bytes_size in all ReadRequests) - (sum of bytes_size in all ReadResponses)'
* server will keep A (available size for responses) non-negative.
* But there is an exception. If server receives ReadRequest, and the first message in response exceeds A -
* then it will still be delivered, and A will become negative until enough additional ReadRequests.
*
* Example:
* 1) Let client have 200 bytes buffer. It sends ReadRequest with bytes_size = 200;
* 2) Server may return one ReadResponse with bytes_size = 70 and than another 80 bytes response;
* now client buffer has 50 free bytes, server is free to send up to 50 bytes in responses.
* 3) Client processes 100 bytes from buffer, now buffer free space is 150 bytes,
* so client sends ReadRequest with bytes_size = 100;
* 4) Server is free to send up to 50 + 100 = 150 bytes. But the next read message is too big,
* and it sends 160 bytes ReadResponse.
* 5) Let's assume client somehow processes it, and its 200 bytes buffer is free again.
* It should account for excess 10 bytes and send ReadRequest with bytes_size = 210.
*
*
* int64 bytes_size = 1;
* @return This builder for chaining.
*/
public Builder clearBytesSize() {
bitField0_ = (bitField0_ & ~0x00000001);
bytesSize_ = 0L;
onChanged();
return this;
}
@java.lang.Override
public final Builder setUnknownFields(
final com.google.protobuf.UnknownFieldSet unknownFields) {
return super.setUnknownFields(unknownFields);
}
@java.lang.Override
public final Builder mergeUnknownFields(
final com.google.protobuf.UnknownFieldSet unknownFields) {
return super.mergeUnknownFields(unknownFields);
}
// @@protoc_insertion_point(builder_scope:Ydb.Topic.StreamReadMessage.ReadRequest)
}
// @@protoc_insertion_point(class_scope:Ydb.Topic.StreamReadMessage.ReadRequest)
private static final tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadRequest DEFAULT_INSTANCE;
static {
DEFAULT_INSTANCE = new tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadRequest();
}
public static tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadRequest getDefaultInstance() {
return DEFAULT_INSTANCE;
}
private static final com.google.protobuf.Parser
PARSER = new com.google.protobuf.AbstractParser() {
@java.lang.Override
public ReadRequest parsePartialFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
Builder builder = newBuilder();
try {
builder.mergeFrom(input, extensionRegistry);
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.setUnfinishedMessage(builder.buildPartial());
} catch (com.google.protobuf.UninitializedMessageException e) {
throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial());
} catch (java.io.IOException e) {
throw new com.google.protobuf.InvalidProtocolBufferException(e)
.setUnfinishedMessage(builder.buildPartial());
}
return builder.buildPartial();
}
};
public static com.google.protobuf.Parser parser() {
return PARSER;
}
@java.lang.Override
public com.google.protobuf.Parser getParserForType() {
return PARSER;
}
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadRequest getDefaultInstanceForType() {
return DEFAULT_INSTANCE;
}
}
public interface ReadResponseOrBuilder extends
// @@protoc_insertion_point(interface_extends:Ydb.Topic.StreamReadMessage.ReadResponse)
com.google.protobuf.MessageOrBuilder {
/**
*
* Client messages, divided by partitions.
*
*
* repeated .Ydb.Topic.StreamReadMessage.ReadResponse.PartitionData partition_data = 1;
*/
java.util.List
getPartitionDataList();
/**
*
* Client messages, divided by partitions.
*
*
* repeated .Ydb.Topic.StreamReadMessage.ReadResponse.PartitionData partition_data = 1;
*/
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.PartitionData getPartitionData(int index);
/**
*
* Client messages, divided by partitions.
*
*
* repeated .Ydb.Topic.StreamReadMessage.ReadResponse.PartitionData partition_data = 1;
*/
int getPartitionDataCount();
/**
*
* Client messages, divided by partitions.
*
*
* repeated .Ydb.Topic.StreamReadMessage.ReadResponse.PartitionData partition_data = 1;
*/
java.util.List extends tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.PartitionDataOrBuilder>
getPartitionDataOrBuilderList();
/**
*
* Client messages, divided by partitions.
*
*
* repeated .Ydb.Topic.StreamReadMessage.ReadResponse.PartitionData partition_data = 1;
*/
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.PartitionDataOrBuilder getPartitionDataOrBuilder(
int index);
/**
*
* Total size in bytes of this response as calculated by server.
* See ReadRequest comment above.
*
*
* int64 bytes_size = 2;
* @return The bytesSize.
*/
long getBytesSize();
}
/**
*
* Data read.
*
*
* Protobuf type {@code Ydb.Topic.StreamReadMessage.ReadResponse}
*/
public static final class ReadResponse extends
com.google.protobuf.GeneratedMessageV3 implements
// @@protoc_insertion_point(message_implements:Ydb.Topic.StreamReadMessage.ReadResponse)
ReadResponseOrBuilder {
private static final long serialVersionUID = 0L;
// Use ReadResponse.newBuilder() to construct.
private ReadResponse(com.google.protobuf.GeneratedMessageV3.Builder> builder) {
super(builder);
}
private ReadResponse() {
partitionData_ = java.util.Collections.emptyList();
}
@java.lang.Override
@SuppressWarnings({"unused"})
protected java.lang.Object newInstance(
UnusedPrivateParameter unused) {
return new ReadResponse();
}
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_StreamReadMessage_ReadResponse_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_StreamReadMessage_ReadResponse_fieldAccessorTable
.ensureFieldAccessorsInitialized(
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.class, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.Builder.class);
}
public interface MessageDataOrBuilder extends
// @@protoc_insertion_point(interface_extends:Ydb.Topic.StreamReadMessage.ReadResponse.MessageData)
com.google.protobuf.MessageOrBuilder {
/**
*
* Partition offset in partition that assigned for message.
*
*
* int64 offset = 1;
* @return The offset.
*/
long getOffset();
/**
*
* Sequence number that provided with message on write from client.
*
*
* int64 seq_no = 2;
* @return The seqNo.
*/
long getSeqNo();
/**
*
* Timestamp of creation of message provided on write from client.
*
*
* .google.protobuf.Timestamp created_at = 3;
* @return Whether the createdAt field is set.
*/
boolean hasCreatedAt();
/**
*
* Timestamp of creation of message provided on write from client.
*
*
* .google.protobuf.Timestamp created_at = 3;
* @return The createdAt.
*/
com.google.protobuf.Timestamp getCreatedAt();
/**
*
* Timestamp of creation of message provided on write from client.
*
*
* .google.protobuf.Timestamp created_at = 3;
*/
com.google.protobuf.TimestampOrBuilder getCreatedAtOrBuilder();
/**
*
* Compressed client message body.
*
*
* bytes data = 5;
* @return The data.
*/
com.google.protobuf.ByteString getData();
/**
*
* Uncompressed size of client message body.
* sent as is from WriteRequest, without check on server side. May be empty (for writes from old client) or wrong (if bug in writer).
* Use it for optimization purposes only, don't trust it.
*
*
* int64 uncompressed_size = 6;
* @return The uncompressedSize.
*/
long getUncompressedSize();
/**
*
* Filled if message_group_id was set on message write.
*
*
* string message_group_id = 7 [(.Ydb.length) = { ... }
* @return The messageGroupId.
*/
java.lang.String getMessageGroupId();
/**
*
* Filled if message_group_id was set on message write.
*
*
* string message_group_id = 7 [(.Ydb.length) = { ... }
* @return The bytes for messageGroupId.
*/
com.google.protobuf.ByteString
getMessageGroupIdBytes();
/**
* repeated .Ydb.Topic.MetadataItem metadata_items = 8;
*/
java.util.List
getMetadataItemsList();
/**
* repeated .Ydb.Topic.MetadataItem metadata_items = 8;
*/
tech.ydb.proto.topic.YdbTopic.MetadataItem getMetadataItems(int index);
/**
* repeated .Ydb.Topic.MetadataItem metadata_items = 8;
*/
int getMetadataItemsCount();
/**
* repeated .Ydb.Topic.MetadataItem metadata_items = 8;
*/
java.util.List extends tech.ydb.proto.topic.YdbTopic.MetadataItemOrBuilder>
getMetadataItemsOrBuilderList();
/**
* repeated .Ydb.Topic.MetadataItem metadata_items = 8;
*/
tech.ydb.proto.topic.YdbTopic.MetadataItemOrBuilder getMetadataItemsOrBuilder(
int index);
}
/**
*
* One client message representation.
*
*
* Protobuf type {@code Ydb.Topic.StreamReadMessage.ReadResponse.MessageData}
*/
public static final class MessageData extends
com.google.protobuf.GeneratedMessageV3 implements
// @@protoc_insertion_point(message_implements:Ydb.Topic.StreamReadMessage.ReadResponse.MessageData)
MessageDataOrBuilder {
private static final long serialVersionUID = 0L;
// Use MessageData.newBuilder() to construct.
private MessageData(com.google.protobuf.GeneratedMessageV3.Builder> builder) {
super(builder);
}
private MessageData() {
data_ = com.google.protobuf.ByteString.EMPTY;
messageGroupId_ = "";
metadataItems_ = java.util.Collections.emptyList();
}
@java.lang.Override
@SuppressWarnings({"unused"})
protected java.lang.Object newInstance(
UnusedPrivateParameter unused) {
return new MessageData();
}
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_StreamReadMessage_ReadResponse_MessageData_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_StreamReadMessage_ReadResponse_MessageData_fieldAccessorTable
.ensureFieldAccessorsInitialized(
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.MessageData.class, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.MessageData.Builder.class);
}
private int bitField0_;
public static final int OFFSET_FIELD_NUMBER = 1;
private long offset_ = 0L;
/**
*
* Partition offset in partition that assigned for message.
*
*
* int64 offset = 1;
* @return The offset.
*/
@java.lang.Override
public long getOffset() {
return offset_;
}
public static final int SEQ_NO_FIELD_NUMBER = 2;
private long seqNo_ = 0L;
/**
*
* Sequence number that provided with message on write from client.
*
*
* int64 seq_no = 2;
* @return The seqNo.
*/
@java.lang.Override
public long getSeqNo() {
return seqNo_;
}
public static final int CREATED_AT_FIELD_NUMBER = 3;
private com.google.protobuf.Timestamp createdAt_;
/**
*
* Timestamp of creation of message provided on write from client.
*
*
* .google.protobuf.Timestamp created_at = 3;
* @return Whether the createdAt field is set.
*/
@java.lang.Override
public boolean hasCreatedAt() {
return ((bitField0_ & 0x00000001) != 0);
}
/**
*
* Timestamp of creation of message provided on write from client.
*
*
* .google.protobuf.Timestamp created_at = 3;
* @return The createdAt.
*/
@java.lang.Override
public com.google.protobuf.Timestamp getCreatedAt() {
return createdAt_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : createdAt_;
}
/**
*
* Timestamp of creation of message provided on write from client.
*
*
* .google.protobuf.Timestamp created_at = 3;
*/
@java.lang.Override
public com.google.protobuf.TimestampOrBuilder getCreatedAtOrBuilder() {
return createdAt_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : createdAt_;
}
public static final int DATA_FIELD_NUMBER = 5;
private com.google.protobuf.ByteString data_ = com.google.protobuf.ByteString.EMPTY;
/**
*
* Compressed client message body.
*
*
* bytes data = 5;
* @return The data.
*/
@java.lang.Override
public com.google.protobuf.ByteString getData() {
return data_;
}
public static final int UNCOMPRESSED_SIZE_FIELD_NUMBER = 6;
private long uncompressedSize_ = 0L;
/**
*
* Uncompressed size of client message body.
* sent as is from WriteRequest, without check on server side. May be empty (for writes from old client) or wrong (if bug in writer).
* Use it for optimization purposes only, don't trust it.
*
*
* int64 uncompressed_size = 6;
* @return The uncompressedSize.
*/
@java.lang.Override
public long getUncompressedSize() {
return uncompressedSize_;
}
public static final int MESSAGE_GROUP_ID_FIELD_NUMBER = 7;
@SuppressWarnings("serial")
private volatile java.lang.Object messageGroupId_ = "";
/**
*
* Filled if message_group_id was set on message write.
*
*
* string message_group_id = 7 [(.Ydb.length) = { ... }
* @return The messageGroupId.
*/
@java.lang.Override
public java.lang.String getMessageGroupId() {
java.lang.Object ref = messageGroupId_;
if (ref instanceof java.lang.String) {
return (java.lang.String) ref;
} else {
com.google.protobuf.ByteString bs =
(com.google.protobuf.ByteString) ref;
java.lang.String s = bs.toStringUtf8();
messageGroupId_ = s;
return s;
}
}
/**
*
* Filled if message_group_id was set on message write.
*
*
* string message_group_id = 7 [(.Ydb.length) = { ... }
* @return The bytes for messageGroupId.
*/
@java.lang.Override
public com.google.protobuf.ByteString
getMessageGroupIdBytes() {
java.lang.Object ref = messageGroupId_;
if (ref instanceof java.lang.String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
messageGroupId_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
public static final int METADATA_ITEMS_FIELD_NUMBER = 8;
@SuppressWarnings("serial")
private java.util.List metadataItems_;
/**
* repeated .Ydb.Topic.MetadataItem metadata_items = 8;
*/
@java.lang.Override
public java.util.List getMetadataItemsList() {
return metadataItems_;
}
/**
* repeated .Ydb.Topic.MetadataItem metadata_items = 8;
*/
@java.lang.Override
public java.util.List extends tech.ydb.proto.topic.YdbTopic.MetadataItemOrBuilder>
getMetadataItemsOrBuilderList() {
return metadataItems_;
}
/**
* repeated .Ydb.Topic.MetadataItem metadata_items = 8;
*/
@java.lang.Override
public int getMetadataItemsCount() {
return metadataItems_.size();
}
/**
* repeated .Ydb.Topic.MetadataItem metadata_items = 8;
*/
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.MetadataItem getMetadataItems(int index) {
return metadataItems_.get(index);
}
/**
* repeated .Ydb.Topic.MetadataItem metadata_items = 8;
*/
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.MetadataItemOrBuilder getMetadataItemsOrBuilder(
int index) {
return metadataItems_.get(index);
}
private byte memoizedIsInitialized = -1;
@java.lang.Override
public final boolean isInitialized() {
byte isInitialized = memoizedIsInitialized;
if (isInitialized == 1) return true;
if (isInitialized == 0) return false;
memoizedIsInitialized = 1;
return true;
}
@java.lang.Override
public void writeTo(com.google.protobuf.CodedOutputStream output)
throws java.io.IOException {
if (offset_ != 0L) {
output.writeInt64(1, offset_);
}
if (seqNo_ != 0L) {
output.writeInt64(2, seqNo_);
}
if (((bitField0_ & 0x00000001) != 0)) {
output.writeMessage(3, getCreatedAt());
}
if (!data_.isEmpty()) {
output.writeBytes(5, data_);
}
if (uncompressedSize_ != 0L) {
output.writeInt64(6, uncompressedSize_);
}
if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(messageGroupId_)) {
com.google.protobuf.GeneratedMessageV3.writeString(output, 7, messageGroupId_);
}
for (int i = 0; i < metadataItems_.size(); i++) {
output.writeMessage(8, metadataItems_.get(i));
}
getUnknownFields().writeTo(output);
}
@java.lang.Override
public int getSerializedSize() {
int size = memoizedSize;
if (size != -1) return size;
size = 0;
if (offset_ != 0L) {
size += com.google.protobuf.CodedOutputStream
.computeInt64Size(1, offset_);
}
if (seqNo_ != 0L) {
size += com.google.protobuf.CodedOutputStream
.computeInt64Size(2, seqNo_);
}
if (((bitField0_ & 0x00000001) != 0)) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(3, getCreatedAt());
}
if (!data_.isEmpty()) {
size += com.google.protobuf.CodedOutputStream
.computeBytesSize(5, data_);
}
if (uncompressedSize_ != 0L) {
size += com.google.protobuf.CodedOutputStream
.computeInt64Size(6, uncompressedSize_);
}
if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(messageGroupId_)) {
size += com.google.protobuf.GeneratedMessageV3.computeStringSize(7, messageGroupId_);
}
for (int i = 0; i < metadataItems_.size(); i++) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(8, metadataItems_.get(i));
}
size += getUnknownFields().getSerializedSize();
memoizedSize = size;
return size;
}
@java.lang.Override
public boolean equals(final java.lang.Object obj) {
if (obj == this) {
return true;
}
if (!(obj instanceof tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.MessageData)) {
return super.equals(obj);
}
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.MessageData other = (tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.MessageData) obj;
if (getOffset()
!= other.getOffset()) return false;
if (getSeqNo()
!= other.getSeqNo()) return false;
if (hasCreatedAt() != other.hasCreatedAt()) return false;
if (hasCreatedAt()) {
if (!getCreatedAt()
.equals(other.getCreatedAt())) return false;
}
if (!getData()
.equals(other.getData())) return false;
if (getUncompressedSize()
!= other.getUncompressedSize()) return false;
if (!getMessageGroupId()
.equals(other.getMessageGroupId())) return false;
if (!getMetadataItemsList()
.equals(other.getMetadataItemsList())) return false;
if (!getUnknownFields().equals(other.getUnknownFields())) return false;
return true;
}
@java.lang.Override
public int hashCode() {
if (memoizedHashCode != 0) {
return memoizedHashCode;
}
int hash = 41;
hash = (19 * hash) + getDescriptor().hashCode();
hash = (37 * hash) + OFFSET_FIELD_NUMBER;
hash = (53 * hash) + com.google.protobuf.Internal.hashLong(
getOffset());
hash = (37 * hash) + SEQ_NO_FIELD_NUMBER;
hash = (53 * hash) + com.google.protobuf.Internal.hashLong(
getSeqNo());
if (hasCreatedAt()) {
hash = (37 * hash) + CREATED_AT_FIELD_NUMBER;
hash = (53 * hash) + getCreatedAt().hashCode();
}
hash = (37 * hash) + DATA_FIELD_NUMBER;
hash = (53 * hash) + getData().hashCode();
hash = (37 * hash) + UNCOMPRESSED_SIZE_FIELD_NUMBER;
hash = (53 * hash) + com.google.protobuf.Internal.hashLong(
getUncompressedSize());
hash = (37 * hash) + MESSAGE_GROUP_ID_FIELD_NUMBER;
hash = (53 * hash) + getMessageGroupId().hashCode();
if (getMetadataItemsCount() > 0) {
hash = (37 * hash) + METADATA_ITEMS_FIELD_NUMBER;
hash = (53 * hash) + getMetadataItemsList().hashCode();
}
hash = (29 * hash) + getUnknownFields().hashCode();
memoizedHashCode = hash;
return hash;
}
public static tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.MessageData parseFrom(
java.nio.ByteBuffer data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.MessageData parseFrom(
java.nio.ByteBuffer data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.MessageData parseFrom(
com.google.protobuf.ByteString data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.MessageData parseFrom(
com.google.protobuf.ByteString data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.MessageData parseFrom(byte[] data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.MessageData parseFrom(
byte[] data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.MessageData parseFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.MessageData parseFrom(
java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.MessageData parseDelimitedFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input);
}
public static tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.MessageData parseDelimitedFrom(
java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.MessageData parseFrom(
com.google.protobuf.CodedInputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.MessageData parseFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry);
}
@java.lang.Override
public Builder newBuilderForType() { return newBuilder(); }
public static Builder newBuilder() {
return DEFAULT_INSTANCE.toBuilder();
}
public static Builder newBuilder(tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.MessageData prototype) {
return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
}
@java.lang.Override
public Builder toBuilder() {
return this == DEFAULT_INSTANCE
? new Builder() : new Builder().mergeFrom(this);
}
@java.lang.Override
protected Builder newBuilderForType(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
Builder builder = new Builder(parent);
return builder;
}
/**
*
* One client message representation.
*
*
* Protobuf type {@code Ydb.Topic.StreamReadMessage.ReadResponse.MessageData}
*/
public static final class Builder extends
com.google.protobuf.GeneratedMessageV3.Builder implements
// @@protoc_insertion_point(builder_implements:Ydb.Topic.StreamReadMessage.ReadResponse.MessageData)
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.MessageDataOrBuilder {
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_StreamReadMessage_ReadResponse_MessageData_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_StreamReadMessage_ReadResponse_MessageData_fieldAccessorTable
.ensureFieldAccessorsInitialized(
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.MessageData.class, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.MessageData.Builder.class);
}
// Construct using tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.MessageData.newBuilder()
private Builder() {
maybeForceBuilderInitialization();
}
private Builder(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
super(parent);
maybeForceBuilderInitialization();
}
private void maybeForceBuilderInitialization() {
if (com.google.protobuf.GeneratedMessageV3
.alwaysUseFieldBuilders) {
getCreatedAtFieldBuilder();
getMetadataItemsFieldBuilder();
}
}
@java.lang.Override
public Builder clear() {
super.clear();
bitField0_ = 0;
offset_ = 0L;
seqNo_ = 0L;
createdAt_ = null;
if (createdAtBuilder_ != null) {
createdAtBuilder_.dispose();
createdAtBuilder_ = null;
}
data_ = com.google.protobuf.ByteString.EMPTY;
uncompressedSize_ = 0L;
messageGroupId_ = "";
if (metadataItemsBuilder_ == null) {
metadataItems_ = java.util.Collections.emptyList();
} else {
metadataItems_ = null;
metadataItemsBuilder_.clear();
}
bitField0_ = (bitField0_ & ~0x00000040);
return this;
}
@java.lang.Override
public com.google.protobuf.Descriptors.Descriptor
getDescriptorForType() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_StreamReadMessage_ReadResponse_MessageData_descriptor;
}
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.MessageData getDefaultInstanceForType() {
return tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.MessageData.getDefaultInstance();
}
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.MessageData build() {
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.MessageData result = buildPartial();
if (!result.isInitialized()) {
throw newUninitializedMessageException(result);
}
return result;
}
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.MessageData buildPartial() {
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.MessageData result = new tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.MessageData(this);
buildPartialRepeatedFields(result);
if (bitField0_ != 0) { buildPartial0(result); }
onBuilt();
return result;
}
private void buildPartialRepeatedFields(tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.MessageData result) {
if (metadataItemsBuilder_ == null) {
if (((bitField0_ & 0x00000040) != 0)) {
metadataItems_ = java.util.Collections.unmodifiableList(metadataItems_);
bitField0_ = (bitField0_ & ~0x00000040);
}
result.metadataItems_ = metadataItems_;
} else {
result.metadataItems_ = metadataItemsBuilder_.build();
}
}
private void buildPartial0(tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.MessageData result) {
int from_bitField0_ = bitField0_;
if (((from_bitField0_ & 0x00000001) != 0)) {
result.offset_ = offset_;
}
if (((from_bitField0_ & 0x00000002) != 0)) {
result.seqNo_ = seqNo_;
}
int to_bitField0_ = 0;
if (((from_bitField0_ & 0x00000004) != 0)) {
result.createdAt_ = createdAtBuilder_ == null
? createdAt_
: createdAtBuilder_.build();
to_bitField0_ |= 0x00000001;
}
if (((from_bitField0_ & 0x00000008) != 0)) {
result.data_ = data_;
}
if (((from_bitField0_ & 0x00000010) != 0)) {
result.uncompressedSize_ = uncompressedSize_;
}
if (((from_bitField0_ & 0x00000020) != 0)) {
result.messageGroupId_ = messageGroupId_;
}
result.bitField0_ |= to_bitField0_;
}
@java.lang.Override
public Builder clone() {
return super.clone();
}
@java.lang.Override
public Builder setField(
com.google.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) {
return super.setField(field, value);
}
@java.lang.Override
public Builder clearField(
com.google.protobuf.Descriptors.FieldDescriptor field) {
return super.clearField(field);
}
@java.lang.Override
public Builder clearOneof(
com.google.protobuf.Descriptors.OneofDescriptor oneof) {
return super.clearOneof(oneof);
}
@java.lang.Override
public Builder setRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
int index, java.lang.Object value) {
return super.setRepeatedField(field, index, value);
}
@java.lang.Override
public Builder addRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) {
return super.addRepeatedField(field, value);
}
@java.lang.Override
public Builder mergeFrom(com.google.protobuf.Message other) {
if (other instanceof tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.MessageData) {
return mergeFrom((tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.MessageData)other);
} else {
super.mergeFrom(other);
return this;
}
}
public Builder mergeFrom(tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.MessageData other) {
if (other == tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.MessageData.getDefaultInstance()) return this;
if (other.getOffset() != 0L) {
setOffset(other.getOffset());
}
if (other.getSeqNo() != 0L) {
setSeqNo(other.getSeqNo());
}
if (other.hasCreatedAt()) {
mergeCreatedAt(other.getCreatedAt());
}
if (other.getData() != com.google.protobuf.ByteString.EMPTY) {
setData(other.getData());
}
if (other.getUncompressedSize() != 0L) {
setUncompressedSize(other.getUncompressedSize());
}
if (!other.getMessageGroupId().isEmpty()) {
messageGroupId_ = other.messageGroupId_;
bitField0_ |= 0x00000020;
onChanged();
}
if (metadataItemsBuilder_ == null) {
if (!other.metadataItems_.isEmpty()) {
if (metadataItems_.isEmpty()) {
metadataItems_ = other.metadataItems_;
bitField0_ = (bitField0_ & ~0x00000040);
} else {
ensureMetadataItemsIsMutable();
metadataItems_.addAll(other.metadataItems_);
}
onChanged();
}
} else {
if (!other.metadataItems_.isEmpty()) {
if (metadataItemsBuilder_.isEmpty()) {
metadataItemsBuilder_.dispose();
metadataItemsBuilder_ = null;
metadataItems_ = other.metadataItems_;
bitField0_ = (bitField0_ & ~0x00000040);
metadataItemsBuilder_ =
com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders ?
getMetadataItemsFieldBuilder() : null;
} else {
metadataItemsBuilder_.addAllMessages(other.metadataItems_);
}
}
}
this.mergeUnknownFields(other.getUnknownFields());
onChanged();
return this;
}
@java.lang.Override
public final boolean isInitialized() {
return true;
}
@java.lang.Override
public Builder mergeFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
if (extensionRegistry == null) {
throw new java.lang.NullPointerException();
}
try {
boolean done = false;
while (!done) {
int tag = input.readTag();
switch (tag) {
case 0:
done = true;
break;
case 8: {
offset_ = input.readInt64();
bitField0_ |= 0x00000001;
break;
} // case 8
case 16: {
seqNo_ = input.readInt64();
bitField0_ |= 0x00000002;
break;
} // case 16
case 26: {
input.readMessage(
getCreatedAtFieldBuilder().getBuilder(),
extensionRegistry);
bitField0_ |= 0x00000004;
break;
} // case 26
case 42: {
data_ = input.readBytes();
bitField0_ |= 0x00000008;
break;
} // case 42
case 48: {
uncompressedSize_ = input.readInt64();
bitField0_ |= 0x00000010;
break;
} // case 48
case 58: {
messageGroupId_ = input.readStringRequireUtf8();
bitField0_ |= 0x00000020;
break;
} // case 58
case 66: {
tech.ydb.proto.topic.YdbTopic.MetadataItem m =
input.readMessage(
tech.ydb.proto.topic.YdbTopic.MetadataItem.parser(),
extensionRegistry);
if (metadataItemsBuilder_ == null) {
ensureMetadataItemsIsMutable();
metadataItems_.add(m);
} else {
metadataItemsBuilder_.addMessage(m);
}
break;
} // case 66
default: {
if (!super.parseUnknownField(input, extensionRegistry, tag)) {
done = true; // was an endgroup tag
}
break;
} // default:
} // switch (tag)
} // while (!done)
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.unwrapIOException();
} finally {
onChanged();
} // finally
return this;
}
private int bitField0_;
private long offset_ ;
/**
*
* Partition offset in partition that assigned for message.
*
*
* int64 offset = 1;
* @return The offset.
*/
@java.lang.Override
public long getOffset() {
return offset_;
}
/**
*
* Partition offset in partition that assigned for message.
*
*
* int64 offset = 1;
* @param value The offset to set.
* @return This builder for chaining.
*/
public Builder setOffset(long value) {
offset_ = value;
bitField0_ |= 0x00000001;
onChanged();
return this;
}
/**
*
* Partition offset in partition that assigned for message.
*
*
* int64 offset = 1;
* @return This builder for chaining.
*/
public Builder clearOffset() {
bitField0_ = (bitField0_ & ~0x00000001);
offset_ = 0L;
onChanged();
return this;
}
private long seqNo_ ;
/**
*
* Sequence number that provided with message on write from client.
*
*
* int64 seq_no = 2;
* @return The seqNo.
*/
@java.lang.Override
public long getSeqNo() {
return seqNo_;
}
/**
*
* Sequence number that provided with message on write from client.
*
*
* int64 seq_no = 2;
* @param value The seqNo to set.
* @return This builder for chaining.
*/
public Builder setSeqNo(long value) {
seqNo_ = value;
bitField0_ |= 0x00000002;
onChanged();
return this;
}
/**
*
* Sequence number that provided with message on write from client.
*
*
* int64 seq_no = 2;
* @return This builder for chaining.
*/
public Builder clearSeqNo() {
bitField0_ = (bitField0_ & ~0x00000002);
seqNo_ = 0L;
onChanged();
return this;
}
private com.google.protobuf.Timestamp createdAt_;
private com.google.protobuf.SingleFieldBuilderV3<
com.google.protobuf.Timestamp, com.google.protobuf.Timestamp.Builder, com.google.protobuf.TimestampOrBuilder> createdAtBuilder_;
/**
*
* Timestamp of creation of message provided on write from client.
*
*
* .google.protobuf.Timestamp created_at = 3;
* @return Whether the createdAt field is set.
*/
public boolean hasCreatedAt() {
return ((bitField0_ & 0x00000004) != 0);
}
/**
*
* Timestamp of creation of message provided on write from client.
*
*
* .google.protobuf.Timestamp created_at = 3;
* @return The createdAt.
*/
public com.google.protobuf.Timestamp getCreatedAt() {
if (createdAtBuilder_ == null) {
return createdAt_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : createdAt_;
} else {
return createdAtBuilder_.getMessage();
}
}
/**
*
* Timestamp of creation of message provided on write from client.
*
*
* .google.protobuf.Timestamp created_at = 3;
*/
public Builder setCreatedAt(com.google.protobuf.Timestamp value) {
if (createdAtBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
createdAt_ = value;
} else {
createdAtBuilder_.setMessage(value);
}
bitField0_ |= 0x00000004;
onChanged();
return this;
}
/**
*
* Timestamp of creation of message provided on write from client.
*
*
* .google.protobuf.Timestamp created_at = 3;
*/
public Builder setCreatedAt(
com.google.protobuf.Timestamp.Builder builderForValue) {
if (createdAtBuilder_ == null) {
createdAt_ = builderForValue.build();
} else {
createdAtBuilder_.setMessage(builderForValue.build());
}
bitField0_ |= 0x00000004;
onChanged();
return this;
}
/**
*
* Timestamp of creation of message provided on write from client.
*
*
* .google.protobuf.Timestamp created_at = 3;
*/
public Builder mergeCreatedAt(com.google.protobuf.Timestamp value) {
if (createdAtBuilder_ == null) {
if (((bitField0_ & 0x00000004) != 0) &&
createdAt_ != null &&
createdAt_ != com.google.protobuf.Timestamp.getDefaultInstance()) {
getCreatedAtBuilder().mergeFrom(value);
} else {
createdAt_ = value;
}
} else {
createdAtBuilder_.mergeFrom(value);
}
if (createdAt_ != null) {
bitField0_ |= 0x00000004;
onChanged();
}
return this;
}
/**
*
* Timestamp of creation of message provided on write from client.
*
*
* .google.protobuf.Timestamp created_at = 3;
*/
public Builder clearCreatedAt() {
bitField0_ = (bitField0_ & ~0x00000004);
createdAt_ = null;
if (createdAtBuilder_ != null) {
createdAtBuilder_.dispose();
createdAtBuilder_ = null;
}
onChanged();
return this;
}
/**
*
* Timestamp of creation of message provided on write from client.
*
*
* .google.protobuf.Timestamp created_at = 3;
*/
public com.google.protobuf.Timestamp.Builder getCreatedAtBuilder() {
bitField0_ |= 0x00000004;
onChanged();
return getCreatedAtFieldBuilder().getBuilder();
}
/**
*
* Timestamp of creation of message provided on write from client.
*
*
* .google.protobuf.Timestamp created_at = 3;
*/
public com.google.protobuf.TimestampOrBuilder getCreatedAtOrBuilder() {
if (createdAtBuilder_ != null) {
return createdAtBuilder_.getMessageOrBuilder();
} else {
return createdAt_ == null ?
com.google.protobuf.Timestamp.getDefaultInstance() : createdAt_;
}
}
/**
*
* Timestamp of creation of message provided on write from client.
*
*
* .google.protobuf.Timestamp created_at = 3;
*/
private com.google.protobuf.SingleFieldBuilderV3<
com.google.protobuf.Timestamp, com.google.protobuf.Timestamp.Builder, com.google.protobuf.TimestampOrBuilder>
getCreatedAtFieldBuilder() {
if (createdAtBuilder_ == null) {
createdAtBuilder_ = new com.google.protobuf.SingleFieldBuilderV3<
com.google.protobuf.Timestamp, com.google.protobuf.Timestamp.Builder, com.google.protobuf.TimestampOrBuilder>(
getCreatedAt(),
getParentForChildren(),
isClean());
createdAt_ = null;
}
return createdAtBuilder_;
}
private com.google.protobuf.ByteString data_ = com.google.protobuf.ByteString.EMPTY;
/**
*
* Compressed client message body.
*
*
* bytes data = 5;
* @return The data.
*/
@java.lang.Override
public com.google.protobuf.ByteString getData() {
return data_;
}
/**
*
* Compressed client message body.
*
*
* bytes data = 5;
* @param value The data to set.
* @return This builder for chaining.
*/
public Builder setData(com.google.protobuf.ByteString value) {
if (value == null) { throw new NullPointerException(); }
data_ = value;
bitField0_ |= 0x00000008;
onChanged();
return this;
}
/**
*
* Compressed client message body.
*
*
* bytes data = 5;
* @return This builder for chaining.
*/
public Builder clearData() {
bitField0_ = (bitField0_ & ~0x00000008);
data_ = getDefaultInstance().getData();
onChanged();
return this;
}
private long uncompressedSize_ ;
/**
*
* Uncompressed size of client message body.
* sent as is from WriteRequest, without check on server side. May be empty (for writes from old client) or wrong (if bug in writer).
* Use it for optimization purposes only, don't trust it.
*
*
* int64 uncompressed_size = 6;
* @return The uncompressedSize.
*/
@java.lang.Override
public long getUncompressedSize() {
return uncompressedSize_;
}
/**
*
* Uncompressed size of client message body.
* sent as is from WriteRequest, without check on server side. May be empty (for writes from old client) or wrong (if bug in writer).
* Use it for optimization purposes only, don't trust it.
*
*
* int64 uncompressed_size = 6;
* @param value The uncompressedSize to set.
* @return This builder for chaining.
*/
public Builder setUncompressedSize(long value) {
uncompressedSize_ = value;
bitField0_ |= 0x00000010;
onChanged();
return this;
}
/**
*
* Uncompressed size of client message body.
* sent as is from WriteRequest, without check on server side. May be empty (for writes from old client) or wrong (if bug in writer).
* Use it for optimization purposes only, don't trust it.
*
*
* int64 uncompressed_size = 6;
* @return This builder for chaining.
*/
public Builder clearUncompressedSize() {
bitField0_ = (bitField0_ & ~0x00000010);
uncompressedSize_ = 0L;
onChanged();
return this;
}
private java.lang.Object messageGroupId_ = "";
/**
*
* Filled if message_group_id was set on message write.
*
*
* string message_group_id = 7 [(.Ydb.length) = { ... }
* @return The messageGroupId.
*/
public java.lang.String getMessageGroupId() {
java.lang.Object ref = messageGroupId_;
if (!(ref instanceof java.lang.String)) {
com.google.protobuf.ByteString bs =
(com.google.protobuf.ByteString) ref;
java.lang.String s = bs.toStringUtf8();
messageGroupId_ = s;
return s;
} else {
return (java.lang.String) ref;
}
}
/**
*
* Filled if message_group_id was set on message write.
*
*
* string message_group_id = 7 [(.Ydb.length) = { ... }
* @return The bytes for messageGroupId.
*/
public com.google.protobuf.ByteString
getMessageGroupIdBytes() {
java.lang.Object ref = messageGroupId_;
if (ref instanceof String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
messageGroupId_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
/**
*
* Filled if message_group_id was set on message write.
*
*
* string message_group_id = 7 [(.Ydb.length) = { ... }
* @param value The messageGroupId to set.
* @return This builder for chaining.
*/
public Builder setMessageGroupId(
java.lang.String value) {
if (value == null) { throw new NullPointerException(); }
messageGroupId_ = value;
bitField0_ |= 0x00000020;
onChanged();
return this;
}
/**
*
* Filled if message_group_id was set on message write.
*
*
* string message_group_id = 7 [(.Ydb.length) = { ... }
* @return This builder for chaining.
*/
public Builder clearMessageGroupId() {
messageGroupId_ = getDefaultInstance().getMessageGroupId();
bitField0_ = (bitField0_ & ~0x00000020);
onChanged();
return this;
}
/**
*
* Filled if message_group_id was set on message write.
*
*
* string message_group_id = 7 [(.Ydb.length) = { ... }
* @param value The bytes for messageGroupId to set.
* @return This builder for chaining.
*/
public Builder setMessageGroupIdBytes(
com.google.protobuf.ByteString value) {
if (value == null) { throw new NullPointerException(); }
checkByteStringIsUtf8(value);
messageGroupId_ = value;
bitField0_ |= 0x00000020;
onChanged();
return this;
}
private java.util.List metadataItems_ =
java.util.Collections.emptyList();
private void ensureMetadataItemsIsMutable() {
if (!((bitField0_ & 0x00000040) != 0)) {
metadataItems_ = new java.util.ArrayList(metadataItems_);
bitField0_ |= 0x00000040;
}
}
private com.google.protobuf.RepeatedFieldBuilderV3<
tech.ydb.proto.topic.YdbTopic.MetadataItem, tech.ydb.proto.topic.YdbTopic.MetadataItem.Builder, tech.ydb.proto.topic.YdbTopic.MetadataItemOrBuilder> metadataItemsBuilder_;
/**
* repeated .Ydb.Topic.MetadataItem metadata_items = 8;
*/
public java.util.List getMetadataItemsList() {
if (metadataItemsBuilder_ == null) {
return java.util.Collections.unmodifiableList(metadataItems_);
} else {
return metadataItemsBuilder_.getMessageList();
}
}
/**
* repeated .Ydb.Topic.MetadataItem metadata_items = 8;
*/
public int getMetadataItemsCount() {
if (metadataItemsBuilder_ == null) {
return metadataItems_.size();
} else {
return metadataItemsBuilder_.getCount();
}
}
/**
* repeated .Ydb.Topic.MetadataItem metadata_items = 8;
*/
public tech.ydb.proto.topic.YdbTopic.MetadataItem getMetadataItems(int index) {
if (metadataItemsBuilder_ == null) {
return metadataItems_.get(index);
} else {
return metadataItemsBuilder_.getMessage(index);
}
}
/**
* repeated .Ydb.Topic.MetadataItem metadata_items = 8;
*/
public Builder setMetadataItems(
int index, tech.ydb.proto.topic.YdbTopic.MetadataItem value) {
if (metadataItemsBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
ensureMetadataItemsIsMutable();
metadataItems_.set(index, value);
onChanged();
} else {
metadataItemsBuilder_.setMessage(index, value);
}
return this;
}
/**
* repeated .Ydb.Topic.MetadataItem metadata_items = 8;
*/
public Builder setMetadataItems(
int index, tech.ydb.proto.topic.YdbTopic.MetadataItem.Builder builderForValue) {
if (metadataItemsBuilder_ == null) {
ensureMetadataItemsIsMutable();
metadataItems_.set(index, builderForValue.build());
onChanged();
} else {
metadataItemsBuilder_.setMessage(index, builderForValue.build());
}
return this;
}
/**
* repeated .Ydb.Topic.MetadataItem metadata_items = 8;
*/
public Builder addMetadataItems(tech.ydb.proto.topic.YdbTopic.MetadataItem value) {
if (metadataItemsBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
ensureMetadataItemsIsMutable();
metadataItems_.add(value);
onChanged();
} else {
metadataItemsBuilder_.addMessage(value);
}
return this;
}
/**
* repeated .Ydb.Topic.MetadataItem metadata_items = 8;
*/
public Builder addMetadataItems(
int index, tech.ydb.proto.topic.YdbTopic.MetadataItem value) {
if (metadataItemsBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
ensureMetadataItemsIsMutable();
metadataItems_.add(index, value);
onChanged();
} else {
metadataItemsBuilder_.addMessage(index, value);
}
return this;
}
/**
* repeated .Ydb.Topic.MetadataItem metadata_items = 8;
*/
public Builder addMetadataItems(
tech.ydb.proto.topic.YdbTopic.MetadataItem.Builder builderForValue) {
if (metadataItemsBuilder_ == null) {
ensureMetadataItemsIsMutable();
metadataItems_.add(builderForValue.build());
onChanged();
} else {
metadataItemsBuilder_.addMessage(builderForValue.build());
}
return this;
}
/**
* repeated .Ydb.Topic.MetadataItem metadata_items = 8;
*/
public Builder addMetadataItems(
int index, tech.ydb.proto.topic.YdbTopic.MetadataItem.Builder builderForValue) {
if (metadataItemsBuilder_ == null) {
ensureMetadataItemsIsMutable();
metadataItems_.add(index, builderForValue.build());
onChanged();
} else {
metadataItemsBuilder_.addMessage(index, builderForValue.build());
}
return this;
}
/**
* repeated .Ydb.Topic.MetadataItem metadata_items = 8;
*/
public Builder addAllMetadataItems(
java.lang.Iterable extends tech.ydb.proto.topic.YdbTopic.MetadataItem> values) {
if (metadataItemsBuilder_ == null) {
ensureMetadataItemsIsMutable();
com.google.protobuf.AbstractMessageLite.Builder.addAll(
values, metadataItems_);
onChanged();
} else {
metadataItemsBuilder_.addAllMessages(values);
}
return this;
}
/**
* repeated .Ydb.Topic.MetadataItem metadata_items = 8;
*/
public Builder clearMetadataItems() {
if (metadataItemsBuilder_ == null) {
metadataItems_ = java.util.Collections.emptyList();
bitField0_ = (bitField0_ & ~0x00000040);
onChanged();
} else {
metadataItemsBuilder_.clear();
}
return this;
}
/**
* repeated .Ydb.Topic.MetadataItem metadata_items = 8;
*/
public Builder removeMetadataItems(int index) {
if (metadataItemsBuilder_ == null) {
ensureMetadataItemsIsMutable();
metadataItems_.remove(index);
onChanged();
} else {
metadataItemsBuilder_.remove(index);
}
return this;
}
/**
* repeated .Ydb.Topic.MetadataItem metadata_items = 8;
*/
public tech.ydb.proto.topic.YdbTopic.MetadataItem.Builder getMetadataItemsBuilder(
int index) {
return getMetadataItemsFieldBuilder().getBuilder(index);
}
/**
* repeated .Ydb.Topic.MetadataItem metadata_items = 8;
*/
public tech.ydb.proto.topic.YdbTopic.MetadataItemOrBuilder getMetadataItemsOrBuilder(
int index) {
if (metadataItemsBuilder_ == null) {
return metadataItems_.get(index); } else {
return metadataItemsBuilder_.getMessageOrBuilder(index);
}
}
/**
* repeated .Ydb.Topic.MetadataItem metadata_items = 8;
*/
public java.util.List extends tech.ydb.proto.topic.YdbTopic.MetadataItemOrBuilder>
getMetadataItemsOrBuilderList() {
if (metadataItemsBuilder_ != null) {
return metadataItemsBuilder_.getMessageOrBuilderList();
} else {
return java.util.Collections.unmodifiableList(metadataItems_);
}
}
/**
* repeated .Ydb.Topic.MetadataItem metadata_items = 8;
*/
public tech.ydb.proto.topic.YdbTopic.MetadataItem.Builder addMetadataItemsBuilder() {
return getMetadataItemsFieldBuilder().addBuilder(
tech.ydb.proto.topic.YdbTopic.MetadataItem.getDefaultInstance());
}
/**
* repeated .Ydb.Topic.MetadataItem metadata_items = 8;
*/
public tech.ydb.proto.topic.YdbTopic.MetadataItem.Builder addMetadataItemsBuilder(
int index) {
return getMetadataItemsFieldBuilder().addBuilder(
index, tech.ydb.proto.topic.YdbTopic.MetadataItem.getDefaultInstance());
}
/**
* repeated .Ydb.Topic.MetadataItem metadata_items = 8;
*/
public java.util.List
getMetadataItemsBuilderList() {
return getMetadataItemsFieldBuilder().getBuilderList();
}
private com.google.protobuf.RepeatedFieldBuilderV3<
tech.ydb.proto.topic.YdbTopic.MetadataItem, tech.ydb.proto.topic.YdbTopic.MetadataItem.Builder, tech.ydb.proto.topic.YdbTopic.MetadataItemOrBuilder>
getMetadataItemsFieldBuilder() {
if (metadataItemsBuilder_ == null) {
metadataItemsBuilder_ = new com.google.protobuf.RepeatedFieldBuilderV3<
tech.ydb.proto.topic.YdbTopic.MetadataItem, tech.ydb.proto.topic.YdbTopic.MetadataItem.Builder, tech.ydb.proto.topic.YdbTopic.MetadataItemOrBuilder>(
metadataItems_,
((bitField0_ & 0x00000040) != 0),
getParentForChildren(),
isClean());
metadataItems_ = null;
}
return metadataItemsBuilder_;
}
@java.lang.Override
public final Builder setUnknownFields(
final com.google.protobuf.UnknownFieldSet unknownFields) {
return super.setUnknownFields(unknownFields);
}
@java.lang.Override
public final Builder mergeUnknownFields(
final com.google.protobuf.UnknownFieldSet unknownFields) {
return super.mergeUnknownFields(unknownFields);
}
// @@protoc_insertion_point(builder_scope:Ydb.Topic.StreamReadMessage.ReadResponse.MessageData)
}
// @@protoc_insertion_point(class_scope:Ydb.Topic.StreamReadMessage.ReadResponse.MessageData)
private static final tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.MessageData DEFAULT_INSTANCE;
static {
DEFAULT_INSTANCE = new tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.MessageData();
}
public static tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.MessageData getDefaultInstance() {
return DEFAULT_INSTANCE;
}
private static final com.google.protobuf.Parser
PARSER = new com.google.protobuf.AbstractParser() {
@java.lang.Override
public MessageData parsePartialFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
Builder builder = newBuilder();
try {
builder.mergeFrom(input, extensionRegistry);
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.setUnfinishedMessage(builder.buildPartial());
} catch (com.google.protobuf.UninitializedMessageException e) {
throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial());
} catch (java.io.IOException e) {
throw new com.google.protobuf.InvalidProtocolBufferException(e)
.setUnfinishedMessage(builder.buildPartial());
}
return builder.buildPartial();
}
};
public static com.google.protobuf.Parser parser() {
return PARSER;
}
@java.lang.Override
public com.google.protobuf.Parser getParserForType() {
return PARSER;
}
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.MessageData getDefaultInstanceForType() {
return DEFAULT_INSTANCE;
}
}
public interface BatchOrBuilder extends
// @@protoc_insertion_point(interface_extends:Ydb.Topic.StreamReadMessage.ReadResponse.Batch)
com.google.protobuf.MessageOrBuilder {
/**
*
* List of client messages.
*
*
* repeated .Ydb.Topic.StreamReadMessage.ReadResponse.MessageData message_data = 1;
*/
java.util.List
getMessageDataList();
/**
*
* List of client messages.
*
*
* repeated .Ydb.Topic.StreamReadMessage.ReadResponse.MessageData message_data = 1;
*/
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.MessageData getMessageData(int index);
/**
*
* List of client messages.
*
*
* repeated .Ydb.Topic.StreamReadMessage.ReadResponse.MessageData message_data = 1;
*/
int getMessageDataCount();
/**
*
* List of client messages.
*
*
* repeated .Ydb.Topic.StreamReadMessage.ReadResponse.MessageData message_data = 1;
*/
java.util.List extends tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.MessageDataOrBuilder>
getMessageDataOrBuilderList();
/**
*
* List of client messages.
*
*
* repeated .Ydb.Topic.StreamReadMessage.ReadResponse.MessageData message_data = 1;
*/
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.MessageDataOrBuilder getMessageDataOrBuilder(
int index);
/**
*
* Producer identifier provided by client for this batch of client messages.
*
*
* string producer_id = 2 [(.Ydb.length) = { ... }
* @return The producerId.
*/
java.lang.String getProducerId();
/**
*
* Producer identifier provided by client for this batch of client messages.
*
*
* string producer_id = 2 [(.Ydb.length) = { ... }
* @return The bytes for producerId.
*/
com.google.protobuf.ByteString
getProducerIdBytes();
/**
*
* Client metadata attached to write session, the same for all messages in batch.
*
*
* map<string, string> write_session_meta = 3;
*/
int getWriteSessionMetaCount();
/**
*
* Client metadata attached to write session, the same for all messages in batch.
*
*
* map<string, string> write_session_meta = 3;
*/
boolean containsWriteSessionMeta(
java.lang.String key);
/**
* Use {@link #getWriteSessionMetaMap()} instead.
*/
@java.lang.Deprecated
java.util.Map
getWriteSessionMeta();
/**
*
* Client metadata attached to write session, the same for all messages in batch.
*
*
* map<string, string> write_session_meta = 3;
*/
java.util.Map
getWriteSessionMetaMap();
/**
*
* Client metadata attached to write session, the same for all messages in batch.
*
*
* map<string, string> write_session_meta = 3;
*/
/* nullable */
java.lang.String getWriteSessionMetaOrDefault(
java.lang.String key,
/* nullable */
java.lang.String defaultValue);
/**
*
* Client metadata attached to write session, the same for all messages in batch.
*
*
* map<string, string> write_session_meta = 3;
*/
java.lang.String getWriteSessionMetaOrThrow(
java.lang.String key);
/**
*
* Codec that is used for data compression.
* See enum Codec above for values.
*
*
* int32 codec = 4;
* @return The codec.
*/
int getCodec();
/**
*
* Persist timestamp on server for batch.
*
*
* .google.protobuf.Timestamp written_at = 5;
* @return Whether the writtenAt field is set.
*/
boolean hasWrittenAt();
/**
*
* Persist timestamp on server for batch.
*
*
* .google.protobuf.Timestamp written_at = 5;
* @return The writtenAt.
*/
com.google.protobuf.Timestamp getWrittenAt();
/**
*
* Persist timestamp on server for batch.
*
*
* .google.protobuf.Timestamp written_at = 5;
*/
com.google.protobuf.TimestampOrBuilder getWrittenAtOrBuilder();
}
/**
*
* Representation of sequence of client messages from one write session.
*
*
* Protobuf type {@code Ydb.Topic.StreamReadMessage.ReadResponse.Batch}
*/
public static final class Batch extends
com.google.protobuf.GeneratedMessageV3 implements
// @@protoc_insertion_point(message_implements:Ydb.Topic.StreamReadMessage.ReadResponse.Batch)
BatchOrBuilder {
private static final long serialVersionUID = 0L;
// Use Batch.newBuilder() to construct.
private Batch(com.google.protobuf.GeneratedMessageV3.Builder> builder) {
super(builder);
}
private Batch() {
messageData_ = java.util.Collections.emptyList();
producerId_ = "";
}
@java.lang.Override
@SuppressWarnings({"unused"})
protected java.lang.Object newInstance(
UnusedPrivateParameter unused) {
return new Batch();
}
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_StreamReadMessage_ReadResponse_Batch_descriptor;
}
@SuppressWarnings({"rawtypes"})
@java.lang.Override
protected com.google.protobuf.MapField internalGetMapField(
int number) {
switch (number) {
case 3:
return internalGetWriteSessionMeta();
default:
throw new RuntimeException(
"Invalid map field number: " + number);
}
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_StreamReadMessage_ReadResponse_Batch_fieldAccessorTable
.ensureFieldAccessorsInitialized(
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.Batch.class, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.Batch.Builder.class);
}
private int bitField0_;
public static final int MESSAGE_DATA_FIELD_NUMBER = 1;
@SuppressWarnings("serial")
private java.util.List messageData_;
/**
*
* List of client messages.
*
*
* repeated .Ydb.Topic.StreamReadMessage.ReadResponse.MessageData message_data = 1;
*/
@java.lang.Override
public java.util.List getMessageDataList() {
return messageData_;
}
/**
*
* List of client messages.
*
*
* repeated .Ydb.Topic.StreamReadMessage.ReadResponse.MessageData message_data = 1;
*/
@java.lang.Override
public java.util.List extends tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.MessageDataOrBuilder>
getMessageDataOrBuilderList() {
return messageData_;
}
/**
*
* List of client messages.
*
*
* repeated .Ydb.Topic.StreamReadMessage.ReadResponse.MessageData message_data = 1;
*/
@java.lang.Override
public int getMessageDataCount() {
return messageData_.size();
}
/**
*
* List of client messages.
*
*
* repeated .Ydb.Topic.StreamReadMessage.ReadResponse.MessageData message_data = 1;
*/
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.MessageData getMessageData(int index) {
return messageData_.get(index);
}
/**
*
* List of client messages.
*
*
* repeated .Ydb.Topic.StreamReadMessage.ReadResponse.MessageData message_data = 1;
*/
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.MessageDataOrBuilder getMessageDataOrBuilder(
int index) {
return messageData_.get(index);
}
public static final int PRODUCER_ID_FIELD_NUMBER = 2;
@SuppressWarnings("serial")
private volatile java.lang.Object producerId_ = "";
/**
*
* Producer identifier provided by client for this batch of client messages.
*
*
* string producer_id = 2 [(.Ydb.length) = { ... }
* @return The producerId.
*/
@java.lang.Override
public java.lang.String getProducerId() {
java.lang.Object ref = producerId_;
if (ref instanceof java.lang.String) {
return (java.lang.String) ref;
} else {
com.google.protobuf.ByteString bs =
(com.google.protobuf.ByteString) ref;
java.lang.String s = bs.toStringUtf8();
producerId_ = s;
return s;
}
}
/**
*
* Producer identifier provided by client for this batch of client messages.
*
*
* string producer_id = 2 [(.Ydb.length) = { ... }
* @return The bytes for producerId.
*/
@java.lang.Override
public com.google.protobuf.ByteString
getProducerIdBytes() {
java.lang.Object ref = producerId_;
if (ref instanceof java.lang.String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
producerId_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
public static final int WRITE_SESSION_META_FIELD_NUMBER = 3;
private static final class WriteSessionMetaDefaultEntryHolder {
static final com.google.protobuf.MapEntry<
java.lang.String, java.lang.String> defaultEntry =
com.google.protobuf.MapEntry
.newDefaultInstance(
tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_StreamReadMessage_ReadResponse_Batch_WriteSessionMetaEntry_descriptor,
com.google.protobuf.WireFormat.FieldType.STRING,
"",
com.google.protobuf.WireFormat.FieldType.STRING,
"");
}
@SuppressWarnings("serial")
private com.google.protobuf.MapField<
java.lang.String, java.lang.String> writeSessionMeta_;
private com.google.protobuf.MapField
internalGetWriteSessionMeta() {
if (writeSessionMeta_ == null) {
return com.google.protobuf.MapField.emptyMapField(
WriteSessionMetaDefaultEntryHolder.defaultEntry);
}
return writeSessionMeta_;
}
public int getWriteSessionMetaCount() {
return internalGetWriteSessionMeta().getMap().size();
}
/**
*
* Client metadata attached to write session, the same for all messages in batch.
*
*
* map<string, string> write_session_meta = 3;
*/
@java.lang.Override
public boolean containsWriteSessionMeta(
java.lang.String key) {
if (key == null) { throw new NullPointerException("map key"); }
return internalGetWriteSessionMeta().getMap().containsKey(key);
}
/**
* Use {@link #getWriteSessionMetaMap()} instead.
*/
@java.lang.Override
@java.lang.Deprecated
public java.util.Map getWriteSessionMeta() {
return getWriteSessionMetaMap();
}
/**
*
* Client metadata attached to write session, the same for all messages in batch.
*
*
* map<string, string> write_session_meta = 3;
*/
@java.lang.Override
public java.util.Map getWriteSessionMetaMap() {
return internalGetWriteSessionMeta().getMap();
}
/**
*
* Client metadata attached to write session, the same for all messages in batch.
*
*
* map<string, string> write_session_meta = 3;
*/
@java.lang.Override
public /* nullable */
java.lang.String getWriteSessionMetaOrDefault(
java.lang.String key,
/* nullable */
java.lang.String defaultValue) {
if (key == null) { throw new NullPointerException("map key"); }
java.util.Map map =
internalGetWriteSessionMeta().getMap();
return map.containsKey(key) ? map.get(key) : defaultValue;
}
/**
*
* Client metadata attached to write session, the same for all messages in batch.
*
*
* map<string, string> write_session_meta = 3;
*/
@java.lang.Override
public java.lang.String getWriteSessionMetaOrThrow(
java.lang.String key) {
if (key == null) { throw new NullPointerException("map key"); }
java.util.Map map =
internalGetWriteSessionMeta().getMap();
if (!map.containsKey(key)) {
throw new java.lang.IllegalArgumentException();
}
return map.get(key);
}
public static final int CODEC_FIELD_NUMBER = 4;
private int codec_ = 0;
/**
*
* Codec that is used for data compression.
* See enum Codec above for values.
*
*
* int32 codec = 4;
* @return The codec.
*/
@java.lang.Override
public int getCodec() {
return codec_;
}
public static final int WRITTEN_AT_FIELD_NUMBER = 5;
private com.google.protobuf.Timestamp writtenAt_;
/**
*
* Persist timestamp on server for batch.
*
*
* .google.protobuf.Timestamp written_at = 5;
* @return Whether the writtenAt field is set.
*/
@java.lang.Override
public boolean hasWrittenAt() {
return ((bitField0_ & 0x00000001) != 0);
}
/**
*
* Persist timestamp on server for batch.
*
*
* .google.protobuf.Timestamp written_at = 5;
* @return The writtenAt.
*/
@java.lang.Override
public com.google.protobuf.Timestamp getWrittenAt() {
return writtenAt_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : writtenAt_;
}
/**
*
* Persist timestamp on server for batch.
*
*
* .google.protobuf.Timestamp written_at = 5;
*/
@java.lang.Override
public com.google.protobuf.TimestampOrBuilder getWrittenAtOrBuilder() {
return writtenAt_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : writtenAt_;
}
private byte memoizedIsInitialized = -1;
@java.lang.Override
public final boolean isInitialized() {
byte isInitialized = memoizedIsInitialized;
if (isInitialized == 1) return true;
if (isInitialized == 0) return false;
memoizedIsInitialized = 1;
return true;
}
@java.lang.Override
public void writeTo(com.google.protobuf.CodedOutputStream output)
throws java.io.IOException {
for (int i = 0; i < messageData_.size(); i++) {
output.writeMessage(1, messageData_.get(i));
}
if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(producerId_)) {
com.google.protobuf.GeneratedMessageV3.writeString(output, 2, producerId_);
}
com.google.protobuf.GeneratedMessageV3
.serializeStringMapTo(
output,
internalGetWriteSessionMeta(),
WriteSessionMetaDefaultEntryHolder.defaultEntry,
3);
if (codec_ != 0) {
output.writeInt32(4, codec_);
}
if (((bitField0_ & 0x00000001) != 0)) {
output.writeMessage(5, getWrittenAt());
}
getUnknownFields().writeTo(output);
}
@java.lang.Override
public int getSerializedSize() {
int size = memoizedSize;
if (size != -1) return size;
size = 0;
for (int i = 0; i < messageData_.size(); i++) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(1, messageData_.get(i));
}
if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(producerId_)) {
size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, producerId_);
}
for (java.util.Map.Entry entry
: internalGetWriteSessionMeta().getMap().entrySet()) {
com.google.protobuf.MapEntry
writeSessionMeta__ = WriteSessionMetaDefaultEntryHolder.defaultEntry.newBuilderForType()
.setKey(entry.getKey())
.setValue(entry.getValue())
.build();
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(3, writeSessionMeta__);
}
if (codec_ != 0) {
size += com.google.protobuf.CodedOutputStream
.computeInt32Size(4, codec_);
}
if (((bitField0_ & 0x00000001) != 0)) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(5, getWrittenAt());
}
size += getUnknownFields().getSerializedSize();
memoizedSize = size;
return size;
}
@java.lang.Override
public boolean equals(final java.lang.Object obj) {
if (obj == this) {
return true;
}
if (!(obj instanceof tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.Batch)) {
return super.equals(obj);
}
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.Batch other = (tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.Batch) obj;
if (!getMessageDataList()
.equals(other.getMessageDataList())) return false;
if (!getProducerId()
.equals(other.getProducerId())) return false;
if (!internalGetWriteSessionMeta().equals(
other.internalGetWriteSessionMeta())) return false;
if (getCodec()
!= other.getCodec()) return false;
if (hasWrittenAt() != other.hasWrittenAt()) return false;
if (hasWrittenAt()) {
if (!getWrittenAt()
.equals(other.getWrittenAt())) return false;
}
if (!getUnknownFields().equals(other.getUnknownFields())) return false;
return true;
}
@java.lang.Override
public int hashCode() {
if (memoizedHashCode != 0) {
return memoizedHashCode;
}
int hash = 41;
hash = (19 * hash) + getDescriptor().hashCode();
if (getMessageDataCount() > 0) {
hash = (37 * hash) + MESSAGE_DATA_FIELD_NUMBER;
hash = (53 * hash) + getMessageDataList().hashCode();
}
hash = (37 * hash) + PRODUCER_ID_FIELD_NUMBER;
hash = (53 * hash) + getProducerId().hashCode();
if (!internalGetWriteSessionMeta().getMap().isEmpty()) {
hash = (37 * hash) + WRITE_SESSION_META_FIELD_NUMBER;
hash = (53 * hash) + internalGetWriteSessionMeta().hashCode();
}
hash = (37 * hash) + CODEC_FIELD_NUMBER;
hash = (53 * hash) + getCodec();
if (hasWrittenAt()) {
hash = (37 * hash) + WRITTEN_AT_FIELD_NUMBER;
hash = (53 * hash) + getWrittenAt().hashCode();
}
hash = (29 * hash) + getUnknownFields().hashCode();
memoizedHashCode = hash;
return hash;
}
public static tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.Batch parseFrom(
java.nio.ByteBuffer data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.Batch parseFrom(
java.nio.ByteBuffer data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.Batch parseFrom(
com.google.protobuf.ByteString data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.Batch parseFrom(
com.google.protobuf.ByteString data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.Batch parseFrom(byte[] data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.Batch parseFrom(
byte[] data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.Batch parseFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.Batch parseFrom(
java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.Batch parseDelimitedFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input);
}
public static tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.Batch parseDelimitedFrom(
java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.Batch parseFrom(
com.google.protobuf.CodedInputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.Batch parseFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry);
}
@java.lang.Override
public Builder newBuilderForType() { return newBuilder(); }
public static Builder newBuilder() {
return DEFAULT_INSTANCE.toBuilder();
}
public static Builder newBuilder(tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.Batch prototype) {
return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
}
@java.lang.Override
public Builder toBuilder() {
return this == DEFAULT_INSTANCE
? new Builder() : new Builder().mergeFrom(this);
}
@java.lang.Override
protected Builder newBuilderForType(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
Builder builder = new Builder(parent);
return builder;
}
/**
*
* Representation of sequence of client messages from one write session.
*
*
* Protobuf type {@code Ydb.Topic.StreamReadMessage.ReadResponse.Batch}
*/
public static final class Builder extends
com.google.protobuf.GeneratedMessageV3.Builder implements
// @@protoc_insertion_point(builder_implements:Ydb.Topic.StreamReadMessage.ReadResponse.Batch)
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.BatchOrBuilder {
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_StreamReadMessage_ReadResponse_Batch_descriptor;
}
@SuppressWarnings({"rawtypes"})
protected com.google.protobuf.MapField internalGetMapField(
int number) {
switch (number) {
case 3:
return internalGetWriteSessionMeta();
default:
throw new RuntimeException(
"Invalid map field number: " + number);
}
}
@SuppressWarnings({"rawtypes"})
protected com.google.protobuf.MapField internalGetMutableMapField(
int number) {
switch (number) {
case 3:
return internalGetMutableWriteSessionMeta();
default:
throw new RuntimeException(
"Invalid map field number: " + number);
}
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_StreamReadMessage_ReadResponse_Batch_fieldAccessorTable
.ensureFieldAccessorsInitialized(
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.Batch.class, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.Batch.Builder.class);
}
// Construct using tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.Batch.newBuilder()
private Builder() {
maybeForceBuilderInitialization();
}
private Builder(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
super(parent);
maybeForceBuilderInitialization();
}
private void maybeForceBuilderInitialization() {
if (com.google.protobuf.GeneratedMessageV3
.alwaysUseFieldBuilders) {
getMessageDataFieldBuilder();
getWrittenAtFieldBuilder();
}
}
@java.lang.Override
public Builder clear() {
super.clear();
bitField0_ = 0;
if (messageDataBuilder_ == null) {
messageData_ = java.util.Collections.emptyList();
} else {
messageData_ = null;
messageDataBuilder_.clear();
}
bitField0_ = (bitField0_ & ~0x00000001);
producerId_ = "";
internalGetMutableWriteSessionMeta().clear();
codec_ = 0;
writtenAt_ = null;
if (writtenAtBuilder_ != null) {
writtenAtBuilder_.dispose();
writtenAtBuilder_ = null;
}
return this;
}
@java.lang.Override
public com.google.protobuf.Descriptors.Descriptor
getDescriptorForType() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_StreamReadMessage_ReadResponse_Batch_descriptor;
}
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.Batch getDefaultInstanceForType() {
return tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.Batch.getDefaultInstance();
}
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.Batch build() {
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.Batch result = buildPartial();
if (!result.isInitialized()) {
throw newUninitializedMessageException(result);
}
return result;
}
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.Batch buildPartial() {
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.Batch result = new tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.Batch(this);
buildPartialRepeatedFields(result);
if (bitField0_ != 0) { buildPartial0(result); }
onBuilt();
return result;
}
private void buildPartialRepeatedFields(tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.Batch result) {
if (messageDataBuilder_ == null) {
if (((bitField0_ & 0x00000001) != 0)) {
messageData_ = java.util.Collections.unmodifiableList(messageData_);
bitField0_ = (bitField0_ & ~0x00000001);
}
result.messageData_ = messageData_;
} else {
result.messageData_ = messageDataBuilder_.build();
}
}
private void buildPartial0(tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.Batch result) {
int from_bitField0_ = bitField0_;
if (((from_bitField0_ & 0x00000002) != 0)) {
result.producerId_ = producerId_;
}
if (((from_bitField0_ & 0x00000004) != 0)) {
result.writeSessionMeta_ = internalGetWriteSessionMeta();
result.writeSessionMeta_.makeImmutable();
}
if (((from_bitField0_ & 0x00000008) != 0)) {
result.codec_ = codec_;
}
int to_bitField0_ = 0;
if (((from_bitField0_ & 0x00000010) != 0)) {
result.writtenAt_ = writtenAtBuilder_ == null
? writtenAt_
: writtenAtBuilder_.build();
to_bitField0_ |= 0x00000001;
}
result.bitField0_ |= to_bitField0_;
}
@java.lang.Override
public Builder clone() {
return super.clone();
}
@java.lang.Override
public Builder setField(
com.google.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) {
return super.setField(field, value);
}
@java.lang.Override
public Builder clearField(
com.google.protobuf.Descriptors.FieldDescriptor field) {
return super.clearField(field);
}
@java.lang.Override
public Builder clearOneof(
com.google.protobuf.Descriptors.OneofDescriptor oneof) {
return super.clearOneof(oneof);
}
@java.lang.Override
public Builder setRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
int index, java.lang.Object value) {
return super.setRepeatedField(field, index, value);
}
@java.lang.Override
public Builder addRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) {
return super.addRepeatedField(field, value);
}
@java.lang.Override
public Builder mergeFrom(com.google.protobuf.Message other) {
if (other instanceof tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.Batch) {
return mergeFrom((tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.Batch)other);
} else {
super.mergeFrom(other);
return this;
}
}
public Builder mergeFrom(tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.Batch other) {
if (other == tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.Batch.getDefaultInstance()) return this;
if (messageDataBuilder_ == null) {
if (!other.messageData_.isEmpty()) {
if (messageData_.isEmpty()) {
messageData_ = other.messageData_;
bitField0_ = (bitField0_ & ~0x00000001);
} else {
ensureMessageDataIsMutable();
messageData_.addAll(other.messageData_);
}
onChanged();
}
} else {
if (!other.messageData_.isEmpty()) {
if (messageDataBuilder_.isEmpty()) {
messageDataBuilder_.dispose();
messageDataBuilder_ = null;
messageData_ = other.messageData_;
bitField0_ = (bitField0_ & ~0x00000001);
messageDataBuilder_ =
com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders ?
getMessageDataFieldBuilder() : null;
} else {
messageDataBuilder_.addAllMessages(other.messageData_);
}
}
}
if (!other.getProducerId().isEmpty()) {
producerId_ = other.producerId_;
bitField0_ |= 0x00000002;
onChanged();
}
internalGetMutableWriteSessionMeta().mergeFrom(
other.internalGetWriteSessionMeta());
bitField0_ |= 0x00000004;
if (other.getCodec() != 0) {
setCodec(other.getCodec());
}
if (other.hasWrittenAt()) {
mergeWrittenAt(other.getWrittenAt());
}
this.mergeUnknownFields(other.getUnknownFields());
onChanged();
return this;
}
@java.lang.Override
public final boolean isInitialized() {
return true;
}
@java.lang.Override
public Builder mergeFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
if (extensionRegistry == null) {
throw new java.lang.NullPointerException();
}
try {
boolean done = false;
while (!done) {
int tag = input.readTag();
switch (tag) {
case 0:
done = true;
break;
case 10: {
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.MessageData m =
input.readMessage(
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.MessageData.parser(),
extensionRegistry);
if (messageDataBuilder_ == null) {
ensureMessageDataIsMutable();
messageData_.add(m);
} else {
messageDataBuilder_.addMessage(m);
}
break;
} // case 10
case 18: {
producerId_ = input.readStringRequireUtf8();
bitField0_ |= 0x00000002;
break;
} // case 18
case 26: {
com.google.protobuf.MapEntry
writeSessionMeta__ = input.readMessage(
WriteSessionMetaDefaultEntryHolder.defaultEntry.getParserForType(), extensionRegistry);
internalGetMutableWriteSessionMeta().getMutableMap().put(
writeSessionMeta__.getKey(), writeSessionMeta__.getValue());
bitField0_ |= 0x00000004;
break;
} // case 26
case 32: {
codec_ = input.readInt32();
bitField0_ |= 0x00000008;
break;
} // case 32
case 42: {
input.readMessage(
getWrittenAtFieldBuilder().getBuilder(),
extensionRegistry);
bitField0_ |= 0x00000010;
break;
} // case 42
default: {
if (!super.parseUnknownField(input, extensionRegistry, tag)) {
done = true; // was an endgroup tag
}
break;
} // default:
} // switch (tag)
} // while (!done)
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.unwrapIOException();
} finally {
onChanged();
} // finally
return this;
}
private int bitField0_;
private java.util.List messageData_ =
java.util.Collections.emptyList();
private void ensureMessageDataIsMutable() {
if (!((bitField0_ & 0x00000001) != 0)) {
messageData_ = new java.util.ArrayList(messageData_);
bitField0_ |= 0x00000001;
}
}
private com.google.protobuf.RepeatedFieldBuilderV3<
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.MessageData, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.MessageData.Builder, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.MessageDataOrBuilder> messageDataBuilder_;
/**
*
* List of client messages.
*
*
* repeated .Ydb.Topic.StreamReadMessage.ReadResponse.MessageData message_data = 1;
*/
public java.util.List getMessageDataList() {
if (messageDataBuilder_ == null) {
return java.util.Collections.unmodifiableList(messageData_);
} else {
return messageDataBuilder_.getMessageList();
}
}
/**
*
* List of client messages.
*
*
* repeated .Ydb.Topic.StreamReadMessage.ReadResponse.MessageData message_data = 1;
*/
public int getMessageDataCount() {
if (messageDataBuilder_ == null) {
return messageData_.size();
} else {
return messageDataBuilder_.getCount();
}
}
/**
*
* List of client messages.
*
*
* repeated .Ydb.Topic.StreamReadMessage.ReadResponse.MessageData message_data = 1;
*/
public tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.MessageData getMessageData(int index) {
if (messageDataBuilder_ == null) {
return messageData_.get(index);
} else {
return messageDataBuilder_.getMessage(index);
}
}
/**
*
* List of client messages.
*
*
* repeated .Ydb.Topic.StreamReadMessage.ReadResponse.MessageData message_data = 1;
*/
public Builder setMessageData(
int index, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.MessageData value) {
if (messageDataBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
ensureMessageDataIsMutable();
messageData_.set(index, value);
onChanged();
} else {
messageDataBuilder_.setMessage(index, value);
}
return this;
}
/**
*
* List of client messages.
*
*
* repeated .Ydb.Topic.StreamReadMessage.ReadResponse.MessageData message_data = 1;
*/
public Builder setMessageData(
int index, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.MessageData.Builder builderForValue) {
if (messageDataBuilder_ == null) {
ensureMessageDataIsMutable();
messageData_.set(index, builderForValue.build());
onChanged();
} else {
messageDataBuilder_.setMessage(index, builderForValue.build());
}
return this;
}
/**
*
* List of client messages.
*
*
* repeated .Ydb.Topic.StreamReadMessage.ReadResponse.MessageData message_data = 1;
*/
public Builder addMessageData(tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.MessageData value) {
if (messageDataBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
ensureMessageDataIsMutable();
messageData_.add(value);
onChanged();
} else {
messageDataBuilder_.addMessage(value);
}
return this;
}
/**
*
* List of client messages.
*
*
* repeated .Ydb.Topic.StreamReadMessage.ReadResponse.MessageData message_data = 1;
*/
public Builder addMessageData(
int index, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.MessageData value) {
if (messageDataBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
ensureMessageDataIsMutable();
messageData_.add(index, value);
onChanged();
} else {
messageDataBuilder_.addMessage(index, value);
}
return this;
}
/**
*
* List of client messages.
*
*
* repeated .Ydb.Topic.StreamReadMessage.ReadResponse.MessageData message_data = 1;
*/
public Builder addMessageData(
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.MessageData.Builder builderForValue) {
if (messageDataBuilder_ == null) {
ensureMessageDataIsMutable();
messageData_.add(builderForValue.build());
onChanged();
} else {
messageDataBuilder_.addMessage(builderForValue.build());
}
return this;
}
/**
*
* List of client messages.
*
*
* repeated .Ydb.Topic.StreamReadMessage.ReadResponse.MessageData message_data = 1;
*/
public Builder addMessageData(
int index, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.MessageData.Builder builderForValue) {
if (messageDataBuilder_ == null) {
ensureMessageDataIsMutable();
messageData_.add(index, builderForValue.build());
onChanged();
} else {
messageDataBuilder_.addMessage(index, builderForValue.build());
}
return this;
}
/**
*
* List of client messages.
*
*
* repeated .Ydb.Topic.StreamReadMessage.ReadResponse.MessageData message_data = 1;
*/
public Builder addAllMessageData(
java.lang.Iterable extends tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.MessageData> values) {
if (messageDataBuilder_ == null) {
ensureMessageDataIsMutable();
com.google.protobuf.AbstractMessageLite.Builder.addAll(
values, messageData_);
onChanged();
} else {
messageDataBuilder_.addAllMessages(values);
}
return this;
}
/**
*
* List of client messages.
*
*
* repeated .Ydb.Topic.StreamReadMessage.ReadResponse.MessageData message_data = 1;
*/
public Builder clearMessageData() {
if (messageDataBuilder_ == null) {
messageData_ = java.util.Collections.emptyList();
bitField0_ = (bitField0_ & ~0x00000001);
onChanged();
} else {
messageDataBuilder_.clear();
}
return this;
}
/**
*
* List of client messages.
*
*
* repeated .Ydb.Topic.StreamReadMessage.ReadResponse.MessageData message_data = 1;
*/
public Builder removeMessageData(int index) {
if (messageDataBuilder_ == null) {
ensureMessageDataIsMutable();
messageData_.remove(index);
onChanged();
} else {
messageDataBuilder_.remove(index);
}
return this;
}
/**
*
* List of client messages.
*
*
* repeated .Ydb.Topic.StreamReadMessage.ReadResponse.MessageData message_data = 1;
*/
public tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.MessageData.Builder getMessageDataBuilder(
int index) {
return getMessageDataFieldBuilder().getBuilder(index);
}
/**
*
* List of client messages.
*
*
* repeated .Ydb.Topic.StreamReadMessage.ReadResponse.MessageData message_data = 1;
*/
public tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.MessageDataOrBuilder getMessageDataOrBuilder(
int index) {
if (messageDataBuilder_ == null) {
return messageData_.get(index); } else {
return messageDataBuilder_.getMessageOrBuilder(index);
}
}
/**
*
* List of client messages.
*
*
* repeated .Ydb.Topic.StreamReadMessage.ReadResponse.MessageData message_data = 1;
*/
public java.util.List extends tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.MessageDataOrBuilder>
getMessageDataOrBuilderList() {
if (messageDataBuilder_ != null) {
return messageDataBuilder_.getMessageOrBuilderList();
} else {
return java.util.Collections.unmodifiableList(messageData_);
}
}
/**
*
* List of client messages.
*
*
* repeated .Ydb.Topic.StreamReadMessage.ReadResponse.MessageData message_data = 1;
*/
public tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.MessageData.Builder addMessageDataBuilder() {
return getMessageDataFieldBuilder().addBuilder(
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.MessageData.getDefaultInstance());
}
/**
*
* List of client messages.
*
*
* repeated .Ydb.Topic.StreamReadMessage.ReadResponse.MessageData message_data = 1;
*/
public tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.MessageData.Builder addMessageDataBuilder(
int index) {
return getMessageDataFieldBuilder().addBuilder(
index, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.MessageData.getDefaultInstance());
}
/**
*
* List of client messages.
*
*
* repeated .Ydb.Topic.StreamReadMessage.ReadResponse.MessageData message_data = 1;
*/
public java.util.List
getMessageDataBuilderList() {
return getMessageDataFieldBuilder().getBuilderList();
}
private com.google.protobuf.RepeatedFieldBuilderV3<
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.MessageData, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.MessageData.Builder, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.MessageDataOrBuilder>
getMessageDataFieldBuilder() {
if (messageDataBuilder_ == null) {
messageDataBuilder_ = new com.google.protobuf.RepeatedFieldBuilderV3<
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.MessageData, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.MessageData.Builder, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.MessageDataOrBuilder>(
messageData_,
((bitField0_ & 0x00000001) != 0),
getParentForChildren(),
isClean());
messageData_ = null;
}
return messageDataBuilder_;
}
private java.lang.Object producerId_ = "";
/**
*
* Producer identifier provided by client for this batch of client messages.
*
*
* string producer_id = 2 [(.Ydb.length) = { ... }
* @return The producerId.
*/
public java.lang.String getProducerId() {
java.lang.Object ref = producerId_;
if (!(ref instanceof java.lang.String)) {
com.google.protobuf.ByteString bs =
(com.google.protobuf.ByteString) ref;
java.lang.String s = bs.toStringUtf8();
producerId_ = s;
return s;
} else {
return (java.lang.String) ref;
}
}
/**
*
* Producer identifier provided by client for this batch of client messages.
*
*
* string producer_id = 2 [(.Ydb.length) = { ... }
* @return The bytes for producerId.
*/
public com.google.protobuf.ByteString
getProducerIdBytes() {
java.lang.Object ref = producerId_;
if (ref instanceof String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
producerId_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
/**
*
* Producer identifier provided by client for this batch of client messages.
*
*
* string producer_id = 2 [(.Ydb.length) = { ... }
* @param value The producerId to set.
* @return This builder for chaining.
*/
public Builder setProducerId(
java.lang.String value) {
if (value == null) { throw new NullPointerException(); }
producerId_ = value;
bitField0_ |= 0x00000002;
onChanged();
return this;
}
/**
*
* Producer identifier provided by client for this batch of client messages.
*
*
* string producer_id = 2 [(.Ydb.length) = { ... }
* @return This builder for chaining.
*/
public Builder clearProducerId() {
producerId_ = getDefaultInstance().getProducerId();
bitField0_ = (bitField0_ & ~0x00000002);
onChanged();
return this;
}
/**
*
* Producer identifier provided by client for this batch of client messages.
*
*
* string producer_id = 2 [(.Ydb.length) = { ... }
* @param value The bytes for producerId to set.
* @return This builder for chaining.
*/
public Builder setProducerIdBytes(
com.google.protobuf.ByteString value) {
if (value == null) { throw new NullPointerException(); }
checkByteStringIsUtf8(value);
producerId_ = value;
bitField0_ |= 0x00000002;
onChanged();
return this;
}
private com.google.protobuf.MapField<
java.lang.String, java.lang.String> writeSessionMeta_;
private com.google.protobuf.MapField
internalGetWriteSessionMeta() {
if (writeSessionMeta_ == null) {
return com.google.protobuf.MapField.emptyMapField(
WriteSessionMetaDefaultEntryHolder.defaultEntry);
}
return writeSessionMeta_;
}
private com.google.protobuf.MapField
internalGetMutableWriteSessionMeta() {
if (writeSessionMeta_ == null) {
writeSessionMeta_ = com.google.protobuf.MapField.newMapField(
WriteSessionMetaDefaultEntryHolder.defaultEntry);
}
if (!writeSessionMeta_.isMutable()) {
writeSessionMeta_ = writeSessionMeta_.copy();
}
bitField0_ |= 0x00000004;
onChanged();
return writeSessionMeta_;
}
public int getWriteSessionMetaCount() {
return internalGetWriteSessionMeta().getMap().size();
}
/**
*
* Client metadata attached to write session, the same for all messages in batch.
*
*
* map<string, string> write_session_meta = 3;
*/
@java.lang.Override
public boolean containsWriteSessionMeta(
java.lang.String key) {
if (key == null) { throw new NullPointerException("map key"); }
return internalGetWriteSessionMeta().getMap().containsKey(key);
}
/**
* Use {@link #getWriteSessionMetaMap()} instead.
*/
@java.lang.Override
@java.lang.Deprecated
public java.util.Map getWriteSessionMeta() {
return getWriteSessionMetaMap();
}
/**
*
* Client metadata attached to write session, the same for all messages in batch.
*
*
* map<string, string> write_session_meta = 3;
*/
@java.lang.Override
public java.util.Map getWriteSessionMetaMap() {
return internalGetWriteSessionMeta().getMap();
}
/**
*
* Client metadata attached to write session, the same for all messages in batch.
*
*
* map<string, string> write_session_meta = 3;
*/
@java.lang.Override
public /* nullable */
java.lang.String getWriteSessionMetaOrDefault(
java.lang.String key,
/* nullable */
java.lang.String defaultValue) {
if (key == null) { throw new NullPointerException("map key"); }
java.util.Map map =
internalGetWriteSessionMeta().getMap();
return map.containsKey(key) ? map.get(key) : defaultValue;
}
/**
*
* Client metadata attached to write session, the same for all messages in batch.
*
*
* map<string, string> write_session_meta = 3;
*/
@java.lang.Override
public java.lang.String getWriteSessionMetaOrThrow(
java.lang.String key) {
if (key == null) { throw new NullPointerException("map key"); }
java.util.Map map =
internalGetWriteSessionMeta().getMap();
if (!map.containsKey(key)) {
throw new java.lang.IllegalArgumentException();
}
return map.get(key);
}
public Builder clearWriteSessionMeta() {
bitField0_ = (bitField0_ & ~0x00000004);
internalGetMutableWriteSessionMeta().getMutableMap()
.clear();
return this;
}
/**
*
* Client metadata attached to write session, the same for all messages in batch.
*
*
* map<string, string> write_session_meta = 3;
*/
public Builder removeWriteSessionMeta(
java.lang.String key) {
if (key == null) { throw new NullPointerException("map key"); }
internalGetMutableWriteSessionMeta().getMutableMap()
.remove(key);
return this;
}
/**
* Use alternate mutation accessors instead.
*/
@java.lang.Deprecated
public java.util.Map
getMutableWriteSessionMeta() {
bitField0_ |= 0x00000004;
return internalGetMutableWriteSessionMeta().getMutableMap();
}
/**
*
* Client metadata attached to write session, the same for all messages in batch.
*
*
* map<string, string> write_session_meta = 3;
*/
public Builder putWriteSessionMeta(
java.lang.String key,
java.lang.String value) {
if (key == null) { throw new NullPointerException("map key"); }
if (value == null) { throw new NullPointerException("map value"); }
internalGetMutableWriteSessionMeta().getMutableMap()
.put(key, value);
bitField0_ |= 0x00000004;
return this;
}
/**
*
* Client metadata attached to write session, the same for all messages in batch.
*
*
* map<string, string> write_session_meta = 3;
*/
public Builder putAllWriteSessionMeta(
java.util.Map values) {
internalGetMutableWriteSessionMeta().getMutableMap()
.putAll(values);
bitField0_ |= 0x00000004;
return this;
}
private int codec_ ;
/**
*
* Codec that is used for data compression.
* See enum Codec above for values.
*
*
* int32 codec = 4;
* @return The codec.
*/
@java.lang.Override
public int getCodec() {
return codec_;
}
/**
*
* Codec that is used for data compression.
* See enum Codec above for values.
*
*
* int32 codec = 4;
* @param value The codec to set.
* @return This builder for chaining.
*/
public Builder setCodec(int value) {
codec_ = value;
bitField0_ |= 0x00000008;
onChanged();
return this;
}
/**
*
* Codec that is used for data compression.
* See enum Codec above for values.
*
*
* int32 codec = 4;
* @return This builder for chaining.
*/
public Builder clearCodec() {
bitField0_ = (bitField0_ & ~0x00000008);
codec_ = 0;
onChanged();
return this;
}
private com.google.protobuf.Timestamp writtenAt_;
private com.google.protobuf.SingleFieldBuilderV3<
com.google.protobuf.Timestamp, com.google.protobuf.Timestamp.Builder, com.google.protobuf.TimestampOrBuilder> writtenAtBuilder_;
/**
*
* Persist timestamp on server for batch.
*
*
* .google.protobuf.Timestamp written_at = 5;
* @return Whether the writtenAt field is set.
*/
public boolean hasWrittenAt() {
return ((bitField0_ & 0x00000010) != 0);
}
/**
*
* Persist timestamp on server for batch.
*
*
* .google.protobuf.Timestamp written_at = 5;
* @return The writtenAt.
*/
public com.google.protobuf.Timestamp getWrittenAt() {
if (writtenAtBuilder_ == null) {
return writtenAt_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : writtenAt_;
} else {
return writtenAtBuilder_.getMessage();
}
}
/**
*
* Persist timestamp on server for batch.
*
*
* .google.protobuf.Timestamp written_at = 5;
*/
public Builder setWrittenAt(com.google.protobuf.Timestamp value) {
if (writtenAtBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
writtenAt_ = value;
} else {
writtenAtBuilder_.setMessage(value);
}
bitField0_ |= 0x00000010;
onChanged();
return this;
}
/**
*
* Persist timestamp on server for batch.
*
*
* .google.protobuf.Timestamp written_at = 5;
*/
public Builder setWrittenAt(
com.google.protobuf.Timestamp.Builder builderForValue) {
if (writtenAtBuilder_ == null) {
writtenAt_ = builderForValue.build();
} else {
writtenAtBuilder_.setMessage(builderForValue.build());
}
bitField0_ |= 0x00000010;
onChanged();
return this;
}
/**
*
* Persist timestamp on server for batch.
*
*
* .google.protobuf.Timestamp written_at = 5;
*/
public Builder mergeWrittenAt(com.google.protobuf.Timestamp value) {
if (writtenAtBuilder_ == null) {
if (((bitField0_ & 0x00000010) != 0) &&
writtenAt_ != null &&
writtenAt_ != com.google.protobuf.Timestamp.getDefaultInstance()) {
getWrittenAtBuilder().mergeFrom(value);
} else {
writtenAt_ = value;
}
} else {
writtenAtBuilder_.mergeFrom(value);
}
if (writtenAt_ != null) {
bitField0_ |= 0x00000010;
onChanged();
}
return this;
}
/**
*
* Persist timestamp on server for batch.
*
*
* .google.protobuf.Timestamp written_at = 5;
*/
public Builder clearWrittenAt() {
bitField0_ = (bitField0_ & ~0x00000010);
writtenAt_ = null;
if (writtenAtBuilder_ != null) {
writtenAtBuilder_.dispose();
writtenAtBuilder_ = null;
}
onChanged();
return this;
}
/**
*
* Persist timestamp on server for batch.
*
*
* .google.protobuf.Timestamp written_at = 5;
*/
public com.google.protobuf.Timestamp.Builder getWrittenAtBuilder() {
bitField0_ |= 0x00000010;
onChanged();
return getWrittenAtFieldBuilder().getBuilder();
}
/**
*
* Persist timestamp on server for batch.
*
*
* .google.protobuf.Timestamp written_at = 5;
*/
public com.google.protobuf.TimestampOrBuilder getWrittenAtOrBuilder() {
if (writtenAtBuilder_ != null) {
return writtenAtBuilder_.getMessageOrBuilder();
} else {
return writtenAt_ == null ?
com.google.protobuf.Timestamp.getDefaultInstance() : writtenAt_;
}
}
/**
*
* Persist timestamp on server for batch.
*
*
* .google.protobuf.Timestamp written_at = 5;
*/
private com.google.protobuf.SingleFieldBuilderV3<
com.google.protobuf.Timestamp, com.google.protobuf.Timestamp.Builder, com.google.protobuf.TimestampOrBuilder>
getWrittenAtFieldBuilder() {
if (writtenAtBuilder_ == null) {
writtenAtBuilder_ = new com.google.protobuf.SingleFieldBuilderV3<
com.google.protobuf.Timestamp, com.google.protobuf.Timestamp.Builder, com.google.protobuf.TimestampOrBuilder>(
getWrittenAt(),
getParentForChildren(),
isClean());
writtenAt_ = null;
}
return writtenAtBuilder_;
}
@java.lang.Override
public final Builder setUnknownFields(
final com.google.protobuf.UnknownFieldSet unknownFields) {
return super.setUnknownFields(unknownFields);
}
@java.lang.Override
public final Builder mergeUnknownFields(
final com.google.protobuf.UnknownFieldSet unknownFields) {
return super.mergeUnknownFields(unknownFields);
}
// @@protoc_insertion_point(builder_scope:Ydb.Topic.StreamReadMessage.ReadResponse.Batch)
}
// @@protoc_insertion_point(class_scope:Ydb.Topic.StreamReadMessage.ReadResponse.Batch)
private static final tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.Batch DEFAULT_INSTANCE;
static {
DEFAULT_INSTANCE = new tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.Batch();
}
public static tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.Batch getDefaultInstance() {
return DEFAULT_INSTANCE;
}
private static final com.google.protobuf.Parser
PARSER = new com.google.protobuf.AbstractParser() {
@java.lang.Override
public Batch parsePartialFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
Builder builder = newBuilder();
try {
builder.mergeFrom(input, extensionRegistry);
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.setUnfinishedMessage(builder.buildPartial());
} catch (com.google.protobuf.UninitializedMessageException e) {
throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial());
} catch (java.io.IOException e) {
throw new com.google.protobuf.InvalidProtocolBufferException(e)
.setUnfinishedMessage(builder.buildPartial());
}
return builder.buildPartial();
}
};
public static com.google.protobuf.Parser parser() {
return PARSER;
}
@java.lang.Override
public com.google.protobuf.Parser getParserForType() {
return PARSER;
}
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.Batch getDefaultInstanceForType() {
return DEFAULT_INSTANCE;
}
}
public interface PartitionDataOrBuilder extends
// @@protoc_insertion_point(interface_extends:Ydb.Topic.StreamReadMessage.ReadResponse.PartitionData)
com.google.protobuf.MessageOrBuilder {
/**
* int64 partition_session_id = 1;
* @return The partitionSessionId.
*/
long getPartitionSessionId();
/**
*
* Client messages, divided by write sessions.
*
*
* repeated .Ydb.Topic.StreamReadMessage.ReadResponse.Batch batches = 2;
*/
java.util.List
getBatchesList();
/**
*
* Client messages, divided by write sessions.
*
*
* repeated .Ydb.Topic.StreamReadMessage.ReadResponse.Batch batches = 2;
*/
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.Batch getBatches(int index);
/**
*
* Client messages, divided by write sessions.
*
*
* repeated .Ydb.Topic.StreamReadMessage.ReadResponse.Batch batches = 2;
*/
int getBatchesCount();
/**
*
* Client messages, divided by write sessions.
*
*
* repeated .Ydb.Topic.StreamReadMessage.ReadResponse.Batch batches = 2;
*/
java.util.List extends tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.BatchOrBuilder>
getBatchesOrBuilderList();
/**
*
* Client messages, divided by write sessions.
*
*
* repeated .Ydb.Topic.StreamReadMessage.ReadResponse.Batch batches = 2;
*/
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.BatchOrBuilder getBatchesOrBuilder(
int index);
}
/**
*
* Representation of sequence of messages from one partition.
*
*
* Protobuf type {@code Ydb.Topic.StreamReadMessage.ReadResponse.PartitionData}
*/
public static final class PartitionData extends
com.google.protobuf.GeneratedMessageV3 implements
// @@protoc_insertion_point(message_implements:Ydb.Topic.StreamReadMessage.ReadResponse.PartitionData)
PartitionDataOrBuilder {
private static final long serialVersionUID = 0L;
// Use PartitionData.newBuilder() to construct.
private PartitionData(com.google.protobuf.GeneratedMessageV3.Builder> builder) {
super(builder);
}
private PartitionData() {
batches_ = java.util.Collections.emptyList();
}
@java.lang.Override
@SuppressWarnings({"unused"})
protected java.lang.Object newInstance(
UnusedPrivateParameter unused) {
return new PartitionData();
}
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_StreamReadMessage_ReadResponse_PartitionData_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_StreamReadMessage_ReadResponse_PartitionData_fieldAccessorTable
.ensureFieldAccessorsInitialized(
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.PartitionData.class, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.PartitionData.Builder.class);
}
public static final int PARTITION_SESSION_ID_FIELD_NUMBER = 1;
private long partitionSessionId_ = 0L;
/**
* int64 partition_session_id = 1;
* @return The partitionSessionId.
*/
@java.lang.Override
public long getPartitionSessionId() {
return partitionSessionId_;
}
public static final int BATCHES_FIELD_NUMBER = 2;
@SuppressWarnings("serial")
private java.util.List batches_;
/**
*
* Client messages, divided by write sessions.
*
*
* repeated .Ydb.Topic.StreamReadMessage.ReadResponse.Batch batches = 2;
*/
@java.lang.Override
public java.util.List getBatchesList() {
return batches_;
}
/**
*
* Client messages, divided by write sessions.
*
*
* repeated .Ydb.Topic.StreamReadMessage.ReadResponse.Batch batches = 2;
*/
@java.lang.Override
public java.util.List extends tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.BatchOrBuilder>
getBatchesOrBuilderList() {
return batches_;
}
/**
*
* Client messages, divided by write sessions.
*
*
* repeated .Ydb.Topic.StreamReadMessage.ReadResponse.Batch batches = 2;
*/
@java.lang.Override
public int getBatchesCount() {
return batches_.size();
}
/**
*
* Client messages, divided by write sessions.
*
*
* repeated .Ydb.Topic.StreamReadMessage.ReadResponse.Batch batches = 2;
*/
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.Batch getBatches(int index) {
return batches_.get(index);
}
/**
*
* Client messages, divided by write sessions.
*
*
* repeated .Ydb.Topic.StreamReadMessage.ReadResponse.Batch batches = 2;
*/
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.BatchOrBuilder getBatchesOrBuilder(
int index) {
return batches_.get(index);
}
private byte memoizedIsInitialized = -1;
@java.lang.Override
public final boolean isInitialized() {
byte isInitialized = memoizedIsInitialized;
if (isInitialized == 1) return true;
if (isInitialized == 0) return false;
memoizedIsInitialized = 1;
return true;
}
@java.lang.Override
public void writeTo(com.google.protobuf.CodedOutputStream output)
throws java.io.IOException {
if (partitionSessionId_ != 0L) {
output.writeInt64(1, partitionSessionId_);
}
for (int i = 0; i < batches_.size(); i++) {
output.writeMessage(2, batches_.get(i));
}
getUnknownFields().writeTo(output);
}
@java.lang.Override
public int getSerializedSize() {
int size = memoizedSize;
if (size != -1) return size;
size = 0;
if (partitionSessionId_ != 0L) {
size += com.google.protobuf.CodedOutputStream
.computeInt64Size(1, partitionSessionId_);
}
for (int i = 0; i < batches_.size(); i++) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(2, batches_.get(i));
}
size += getUnknownFields().getSerializedSize();
memoizedSize = size;
return size;
}
@java.lang.Override
public boolean equals(final java.lang.Object obj) {
if (obj == this) {
return true;
}
if (!(obj instanceof tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.PartitionData)) {
return super.equals(obj);
}
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.PartitionData other = (tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.PartitionData) obj;
if (getPartitionSessionId()
!= other.getPartitionSessionId()) return false;
if (!getBatchesList()
.equals(other.getBatchesList())) return false;
if (!getUnknownFields().equals(other.getUnknownFields())) return false;
return true;
}
@java.lang.Override
public int hashCode() {
if (memoizedHashCode != 0) {
return memoizedHashCode;
}
int hash = 41;
hash = (19 * hash) + getDescriptor().hashCode();
hash = (37 * hash) + PARTITION_SESSION_ID_FIELD_NUMBER;
hash = (53 * hash) + com.google.protobuf.Internal.hashLong(
getPartitionSessionId());
if (getBatchesCount() > 0) {
hash = (37 * hash) + BATCHES_FIELD_NUMBER;
hash = (53 * hash) + getBatchesList().hashCode();
}
hash = (29 * hash) + getUnknownFields().hashCode();
memoizedHashCode = hash;
return hash;
}
public static tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.PartitionData parseFrom(
java.nio.ByteBuffer data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.PartitionData parseFrom(
java.nio.ByteBuffer data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.PartitionData parseFrom(
com.google.protobuf.ByteString data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.PartitionData parseFrom(
com.google.protobuf.ByteString data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.PartitionData parseFrom(byte[] data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.PartitionData parseFrom(
byte[] data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.PartitionData parseFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.PartitionData parseFrom(
java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.PartitionData parseDelimitedFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input);
}
public static tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.PartitionData parseDelimitedFrom(
java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input, extensionRegistry);
}
public static tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.PartitionData parseFrom(
com.google.protobuf.CodedInputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.PartitionData parseFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry);
}
@java.lang.Override
public Builder newBuilderForType() { return newBuilder(); }
public static Builder newBuilder() {
return DEFAULT_INSTANCE.toBuilder();
}
public static Builder newBuilder(tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.PartitionData prototype) {
return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
}
@java.lang.Override
public Builder toBuilder() {
return this == DEFAULT_INSTANCE
? new Builder() : new Builder().mergeFrom(this);
}
@java.lang.Override
protected Builder newBuilderForType(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
Builder builder = new Builder(parent);
return builder;
}
/**
*
* Representation of sequence of messages from one partition.
*
*
* Protobuf type {@code Ydb.Topic.StreamReadMessage.ReadResponse.PartitionData}
*/
public static final class Builder extends
com.google.protobuf.GeneratedMessageV3.Builder implements
// @@protoc_insertion_point(builder_implements:Ydb.Topic.StreamReadMessage.ReadResponse.PartitionData)
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.PartitionDataOrBuilder {
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_StreamReadMessage_ReadResponse_PartitionData_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_StreamReadMessage_ReadResponse_PartitionData_fieldAccessorTable
.ensureFieldAccessorsInitialized(
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.PartitionData.class, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.PartitionData.Builder.class);
}
// Construct using tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.PartitionData.newBuilder()
private Builder() {
}
private Builder(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
super(parent);
}
@java.lang.Override
public Builder clear() {
super.clear();
bitField0_ = 0;
partitionSessionId_ = 0L;
if (batchesBuilder_ == null) {
batches_ = java.util.Collections.emptyList();
} else {
batches_ = null;
batchesBuilder_.clear();
}
bitField0_ = (bitField0_ & ~0x00000002);
return this;
}
@java.lang.Override
public com.google.protobuf.Descriptors.Descriptor
getDescriptorForType() {
return tech.ydb.proto.topic.YdbTopic.internal_static_Ydb_Topic_StreamReadMessage_ReadResponse_PartitionData_descriptor;
}
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.PartitionData getDefaultInstanceForType() {
return tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.PartitionData.getDefaultInstance();
}
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.PartitionData build() {
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.PartitionData result = buildPartial();
if (!result.isInitialized()) {
throw newUninitializedMessageException(result);
}
return result;
}
@java.lang.Override
public tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.PartitionData buildPartial() {
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.PartitionData result = new tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.PartitionData(this);
buildPartialRepeatedFields(result);
if (bitField0_ != 0) { buildPartial0(result); }
onBuilt();
return result;
}
private void buildPartialRepeatedFields(tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.PartitionData result) {
if (batchesBuilder_ == null) {
if (((bitField0_ & 0x00000002) != 0)) {
batches_ = java.util.Collections.unmodifiableList(batches_);
bitField0_ = (bitField0_ & ~0x00000002);
}
result.batches_ = batches_;
} else {
result.batches_ = batchesBuilder_.build();
}
}
private void buildPartial0(tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.PartitionData result) {
int from_bitField0_ = bitField0_;
if (((from_bitField0_ & 0x00000001) != 0)) {
result.partitionSessionId_ = partitionSessionId_;
}
}
@java.lang.Override
public Builder clone() {
return super.clone();
}
@java.lang.Override
public Builder setField(
com.google.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) {
return super.setField(field, value);
}
@java.lang.Override
public Builder clearField(
com.google.protobuf.Descriptors.FieldDescriptor field) {
return super.clearField(field);
}
@java.lang.Override
public Builder clearOneof(
com.google.protobuf.Descriptors.OneofDescriptor oneof) {
return super.clearOneof(oneof);
}
@java.lang.Override
public Builder setRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
int index, java.lang.Object value) {
return super.setRepeatedField(field, index, value);
}
@java.lang.Override
public Builder addRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) {
return super.addRepeatedField(field, value);
}
@java.lang.Override
public Builder mergeFrom(com.google.protobuf.Message other) {
if (other instanceof tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.PartitionData) {
return mergeFrom((tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.PartitionData)other);
} else {
super.mergeFrom(other);
return this;
}
}
public Builder mergeFrom(tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.PartitionData other) {
if (other == tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.PartitionData.getDefaultInstance()) return this;
if (other.getPartitionSessionId() != 0L) {
setPartitionSessionId(other.getPartitionSessionId());
}
if (batchesBuilder_ == null) {
if (!other.batches_.isEmpty()) {
if (batches_.isEmpty()) {
batches_ = other.batches_;
bitField0_ = (bitField0_ & ~0x00000002);
} else {
ensureBatchesIsMutable();
batches_.addAll(other.batches_);
}
onChanged();
}
} else {
if (!other.batches_.isEmpty()) {
if (batchesBuilder_.isEmpty()) {
batchesBuilder_.dispose();
batchesBuilder_ = null;
batches_ = other.batches_;
bitField0_ = (bitField0_ & ~0x00000002);
batchesBuilder_ =
com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders ?
getBatchesFieldBuilder() : null;
} else {
batchesBuilder_.addAllMessages(other.batches_);
}
}
}
this.mergeUnknownFields(other.getUnknownFields());
onChanged();
return this;
}
@java.lang.Override
public final boolean isInitialized() {
return true;
}
@java.lang.Override
public Builder mergeFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
if (extensionRegistry == null) {
throw new java.lang.NullPointerException();
}
try {
boolean done = false;
while (!done) {
int tag = input.readTag();
switch (tag) {
case 0:
done = true;
break;
case 8: {
partitionSessionId_ = input.readInt64();
bitField0_ |= 0x00000001;
break;
} // case 8
case 18: {
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.Batch m =
input.readMessage(
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.Batch.parser(),
extensionRegistry);
if (batchesBuilder_ == null) {
ensureBatchesIsMutable();
batches_.add(m);
} else {
batchesBuilder_.addMessage(m);
}
break;
} // case 18
default: {
if (!super.parseUnknownField(input, extensionRegistry, tag)) {
done = true; // was an endgroup tag
}
break;
} // default:
} // switch (tag)
} // while (!done)
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.unwrapIOException();
} finally {
onChanged();
} // finally
return this;
}
private int bitField0_;
private long partitionSessionId_ ;
/**
* int64 partition_session_id = 1;
* @return The partitionSessionId.
*/
@java.lang.Override
public long getPartitionSessionId() {
return partitionSessionId_;
}
/**
* int64 partition_session_id = 1;
* @param value The partitionSessionId to set.
* @return This builder for chaining.
*/
public Builder setPartitionSessionId(long value) {
partitionSessionId_ = value;
bitField0_ |= 0x00000001;
onChanged();
return this;
}
/**
* int64 partition_session_id = 1;
* @return This builder for chaining.
*/
public Builder clearPartitionSessionId() {
bitField0_ = (bitField0_ & ~0x00000001);
partitionSessionId_ = 0L;
onChanged();
return this;
}
private java.util.List batches_ =
java.util.Collections.emptyList();
private void ensureBatchesIsMutable() {
if (!((bitField0_ & 0x00000002) != 0)) {
batches_ = new java.util.ArrayList(batches_);
bitField0_ |= 0x00000002;
}
}
private com.google.protobuf.RepeatedFieldBuilderV3<
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.Batch, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.Batch.Builder, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.BatchOrBuilder> batchesBuilder_;
/**
*
* Client messages, divided by write sessions.
*
*
* repeated .Ydb.Topic.StreamReadMessage.ReadResponse.Batch batches = 2;
*/
public java.util.List getBatchesList() {
if (batchesBuilder_ == null) {
return java.util.Collections.unmodifiableList(batches_);
} else {
return batchesBuilder_.getMessageList();
}
}
/**
*
* Client messages, divided by write sessions.
*
*
* repeated .Ydb.Topic.StreamReadMessage.ReadResponse.Batch batches = 2;
*/
public int getBatchesCount() {
if (batchesBuilder_ == null) {
return batches_.size();
} else {
return batchesBuilder_.getCount();
}
}
/**
*
* Client messages, divided by write sessions.
*
*
* repeated .Ydb.Topic.StreamReadMessage.ReadResponse.Batch batches = 2;
*/
public tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.Batch getBatches(int index) {
if (batchesBuilder_ == null) {
return batches_.get(index);
} else {
return batchesBuilder_.getMessage(index);
}
}
/**
*
* Client messages, divided by write sessions.
*
*
* repeated .Ydb.Topic.StreamReadMessage.ReadResponse.Batch batches = 2;
*/
public Builder setBatches(
int index, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.Batch value) {
if (batchesBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
ensureBatchesIsMutable();
batches_.set(index, value);
onChanged();
} else {
batchesBuilder_.setMessage(index, value);
}
return this;
}
/**
*
* Client messages, divided by write sessions.
*
*
* repeated .Ydb.Topic.StreamReadMessage.ReadResponse.Batch batches = 2;
*/
public Builder setBatches(
int index, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.Batch.Builder builderForValue) {
if (batchesBuilder_ == null) {
ensureBatchesIsMutable();
batches_.set(index, builderForValue.build());
onChanged();
} else {
batchesBuilder_.setMessage(index, builderForValue.build());
}
return this;
}
/**
*
* Client messages, divided by write sessions.
*
*
* repeated .Ydb.Topic.StreamReadMessage.ReadResponse.Batch batches = 2;
*/
public Builder addBatches(tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.Batch value) {
if (batchesBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
ensureBatchesIsMutable();
batches_.add(value);
onChanged();
} else {
batchesBuilder_.addMessage(value);
}
return this;
}
/**
*
* Client messages, divided by write sessions.
*
*
* repeated .Ydb.Topic.StreamReadMessage.ReadResponse.Batch batches = 2;
*/
public Builder addBatches(
int index, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.Batch value) {
if (batchesBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
ensureBatchesIsMutable();
batches_.add(index, value);
onChanged();
} else {
batchesBuilder_.addMessage(index, value);
}
return this;
}
/**
*
* Client messages, divided by write sessions.
*
*
* repeated .Ydb.Topic.StreamReadMessage.ReadResponse.Batch batches = 2;
*/
public Builder addBatches(
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.Batch.Builder builderForValue) {
if (batchesBuilder_ == null) {
ensureBatchesIsMutable();
batches_.add(builderForValue.build());
onChanged();
} else {
batchesBuilder_.addMessage(builderForValue.build());
}
return this;
}
/**
*
* Client messages, divided by write sessions.
*
*
* repeated .Ydb.Topic.StreamReadMessage.ReadResponse.Batch batches = 2;
*/
public Builder addBatches(
int index, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.Batch.Builder builderForValue) {
if (batchesBuilder_ == null) {
ensureBatchesIsMutable();
batches_.add(index, builderForValue.build());
onChanged();
} else {
batchesBuilder_.addMessage(index, builderForValue.build());
}
return this;
}
/**
*
* Client messages, divided by write sessions.
*
*
* repeated .Ydb.Topic.StreamReadMessage.ReadResponse.Batch batches = 2;
*/
public Builder addAllBatches(
java.lang.Iterable extends tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.Batch> values) {
if (batchesBuilder_ == null) {
ensureBatchesIsMutable();
com.google.protobuf.AbstractMessageLite.Builder.addAll(
values, batches_);
onChanged();
} else {
batchesBuilder_.addAllMessages(values);
}
return this;
}
/**
*
* Client messages, divided by write sessions.
*
*
* repeated .Ydb.Topic.StreamReadMessage.ReadResponse.Batch batches = 2;
*/
public Builder clearBatches() {
if (batchesBuilder_ == null) {
batches_ = java.util.Collections.emptyList();
bitField0_ = (bitField0_ & ~0x00000002);
onChanged();
} else {
batchesBuilder_.clear();
}
return this;
}
/**
*
* Client messages, divided by write sessions.
*
*
* repeated .Ydb.Topic.StreamReadMessage.ReadResponse.Batch batches = 2;
*/
public Builder removeBatches(int index) {
if (batchesBuilder_ == null) {
ensureBatchesIsMutable();
batches_.remove(index);
onChanged();
} else {
batchesBuilder_.remove(index);
}
return this;
}
/**
*
* Client messages, divided by write sessions.
*
*
* repeated .Ydb.Topic.StreamReadMessage.ReadResponse.Batch batches = 2;
*/
public tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.Batch.Builder getBatchesBuilder(
int index) {
return getBatchesFieldBuilder().getBuilder(index);
}
/**
*
* Client messages, divided by write sessions.
*
*
* repeated .Ydb.Topic.StreamReadMessage.ReadResponse.Batch batches = 2;
*/
public tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.BatchOrBuilder getBatchesOrBuilder(
int index) {
if (batchesBuilder_ == null) {
return batches_.get(index); } else {
return batchesBuilder_.getMessageOrBuilder(index);
}
}
/**
*
* Client messages, divided by write sessions.
*
*
* repeated .Ydb.Topic.StreamReadMessage.ReadResponse.Batch batches = 2;
*/
public java.util.List extends tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.BatchOrBuilder>
getBatchesOrBuilderList() {
if (batchesBuilder_ != null) {
return batchesBuilder_.getMessageOrBuilderList();
} else {
return java.util.Collections.unmodifiableList(batches_);
}
}
/**
*
* Client messages, divided by write sessions.
*
*
* repeated .Ydb.Topic.StreamReadMessage.ReadResponse.Batch batches = 2;
*/
public tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.Batch.Builder addBatchesBuilder() {
return getBatchesFieldBuilder().addBuilder(
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.Batch.getDefaultInstance());
}
/**
*
* Client messages, divided by write sessions.
*
*
* repeated .Ydb.Topic.StreamReadMessage.ReadResponse.Batch batches = 2;
*/
public tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.Batch.Builder addBatchesBuilder(
int index) {
return getBatchesFieldBuilder().addBuilder(
index, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.Batch.getDefaultInstance());
}
/**
*
* Client messages, divided by write sessions.
*
*
* repeated .Ydb.Topic.StreamReadMessage.ReadResponse.Batch batches = 2;
*/
public java.util.List
getBatchesBuilderList() {
return getBatchesFieldBuilder().getBuilderList();
}
private com.google.protobuf.RepeatedFieldBuilderV3<
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.Batch, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.Batch.Builder, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.BatchOrBuilder>
getBatchesFieldBuilder() {
if (batchesBuilder_ == null) {
batchesBuilder_ = new com.google.protobuf.RepeatedFieldBuilderV3<
tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.Batch, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.Batch.Builder, tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.BatchOrBuilder>(
batches_,
((bitField0_ & 0x00000002) != 0),
getParentForChildren(),
isClean());
batches_ = null;
}
return batchesBuilder_;
}
@java.lang.Override
public final Builder setUnknownFields(
final com.google.protobuf.UnknownFieldSet unknownFields) {
return super.setUnknownFields(unknownFields);
}
@java.lang.Override
public final Builder mergeUnknownFields(
final com.google.protobuf.UnknownFieldSet unknownFields) {
return super.mergeUnknownFields(unknownFields);
}
// @@protoc_insertion_point(builder_scope:Ydb.Topic.StreamReadMessage.ReadResponse.PartitionData)
}
// @@protoc_insertion_point(class_scope:Ydb.Topic.StreamReadMessage.ReadResponse.PartitionData)
private static final tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.PartitionData DEFAULT_INSTANCE;
static {
DEFAULT_INSTANCE = new tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.PartitionData();
}
public static tech.ydb.proto.topic.YdbTopic.StreamReadMessage.ReadResponse.PartitionData getDefaultInstance() {
return DEFAULT_INSTANCE;
}
private static final com.google.protobuf.Parser
PARSER = new com.google.protobuf.AbstractParser