io.milvus.grpc.SearchResultData Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of milvus-sdk-java Show documentation
Show all versions of milvus-sdk-java Show documentation
Java SDK for Milvus, a distributed high-performance vector database.
// Generated by the protocol buffer compiler. DO NOT EDIT!
// source: schema.proto
package io.milvus.grpc;
/**
* Protobuf type {@code milvus.proto.schema.SearchResultData}
*/
public final class SearchResultData extends
com.google.protobuf.GeneratedMessageV3 implements
// @@protoc_insertion_point(message_implements:milvus.proto.schema.SearchResultData)
SearchResultDataOrBuilder {
private static final long serialVersionUID = 0L;
// Use SearchResultData.newBuilder() to construct.
private SearchResultData(com.google.protobuf.GeneratedMessageV3.Builder> builder) {
super(builder);
}
private SearchResultData() {
fieldsData_ = java.util.Collections.emptyList();
scores_ = emptyFloatList();
topks_ = emptyLongList();
outputFields_ =
com.google.protobuf.LazyStringArrayList.emptyList();
distances_ = emptyFloatList();
}
@java.lang.Override
@SuppressWarnings({"unused"})
protected java.lang.Object newInstance(
UnusedPrivateParameter unused) {
return new SearchResultData();
}
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return io.milvus.grpc.SchemaProto.internal_static_milvus_proto_schema_SearchResultData_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return io.milvus.grpc.SchemaProto.internal_static_milvus_proto_schema_SearchResultData_fieldAccessorTable
.ensureFieldAccessorsInitialized(
io.milvus.grpc.SearchResultData.class, io.milvus.grpc.SearchResultData.Builder.class);
}
private int bitField0_;
public static final int NUM_QUERIES_FIELD_NUMBER = 1;
private long numQueries_ = 0L;
/**
* int64 num_queries = 1;
* @return The numQueries.
*/
@java.lang.Override
public long getNumQueries() {
return numQueries_;
}
public static final int TOP_K_FIELD_NUMBER = 2;
private long topK_ = 0L;
/**
* int64 top_k = 2;
* @return The topK.
*/
@java.lang.Override
public long getTopK() {
return topK_;
}
public static final int FIELDS_DATA_FIELD_NUMBER = 3;
@SuppressWarnings("serial")
private java.util.List fieldsData_;
/**
* repeated .milvus.proto.schema.FieldData fields_data = 3;
*/
@java.lang.Override
public java.util.List getFieldsDataList() {
return fieldsData_;
}
/**
* repeated .milvus.proto.schema.FieldData fields_data = 3;
*/
@java.lang.Override
public java.util.List extends io.milvus.grpc.FieldDataOrBuilder>
getFieldsDataOrBuilderList() {
return fieldsData_;
}
/**
* repeated .milvus.proto.schema.FieldData fields_data = 3;
*/
@java.lang.Override
public int getFieldsDataCount() {
return fieldsData_.size();
}
/**
* repeated .milvus.proto.schema.FieldData fields_data = 3;
*/
@java.lang.Override
public io.milvus.grpc.FieldData getFieldsData(int index) {
return fieldsData_.get(index);
}
/**
* repeated .milvus.proto.schema.FieldData fields_data = 3;
*/
@java.lang.Override
public io.milvus.grpc.FieldDataOrBuilder getFieldsDataOrBuilder(
int index) {
return fieldsData_.get(index);
}
public static final int SCORES_FIELD_NUMBER = 4;
@SuppressWarnings("serial")
private com.google.protobuf.Internal.FloatList scores_ =
emptyFloatList();
/**
* repeated float scores = 4;
* @return A list containing the scores.
*/
@java.lang.Override
public java.util.List
getScoresList() {
return scores_;
}
/**
* repeated float scores = 4;
* @return The count of scores.
*/
public int getScoresCount() {
return scores_.size();
}
/**
* repeated float scores = 4;
* @param index The index of the element to return.
* @return The scores at the given index.
*/
public float getScores(int index) {
return scores_.getFloat(index);
}
private int scoresMemoizedSerializedSize = -1;
public static final int IDS_FIELD_NUMBER = 5;
private io.milvus.grpc.IDs ids_;
/**
* .milvus.proto.schema.IDs ids = 5;
* @return Whether the ids field is set.
*/
@java.lang.Override
public boolean hasIds() {
return ((bitField0_ & 0x00000001) != 0);
}
/**
* .milvus.proto.schema.IDs ids = 5;
* @return The ids.
*/
@java.lang.Override
public io.milvus.grpc.IDs getIds() {
return ids_ == null ? io.milvus.grpc.IDs.getDefaultInstance() : ids_;
}
/**
* .milvus.proto.schema.IDs ids = 5;
*/
@java.lang.Override
public io.milvus.grpc.IDsOrBuilder getIdsOrBuilder() {
return ids_ == null ? io.milvus.grpc.IDs.getDefaultInstance() : ids_;
}
public static final int TOPKS_FIELD_NUMBER = 6;
@SuppressWarnings("serial")
private com.google.protobuf.Internal.LongList topks_ =
emptyLongList();
/**
* repeated int64 topks = 6;
* @return A list containing the topks.
*/
@java.lang.Override
public java.util.List
getTopksList() {
return topks_;
}
/**
* repeated int64 topks = 6;
* @return The count of topks.
*/
public int getTopksCount() {
return topks_.size();
}
/**
* repeated int64 topks = 6;
* @param index The index of the element to return.
* @return The topks at the given index.
*/
public long getTopks(int index) {
return topks_.getLong(index);
}
private int topksMemoizedSerializedSize = -1;
public static final int OUTPUT_FIELDS_FIELD_NUMBER = 7;
@SuppressWarnings("serial")
private com.google.protobuf.LazyStringArrayList outputFields_ =
com.google.protobuf.LazyStringArrayList.emptyList();
/**
* repeated string output_fields = 7;
* @return A list containing the outputFields.
*/
public com.google.protobuf.ProtocolStringList
getOutputFieldsList() {
return outputFields_;
}
/**
* repeated string output_fields = 7;
* @return The count of outputFields.
*/
public int getOutputFieldsCount() {
return outputFields_.size();
}
/**
* repeated string output_fields = 7;
* @param index The index of the element to return.
* @return The outputFields at the given index.
*/
public java.lang.String getOutputFields(int index) {
return outputFields_.get(index);
}
/**
* repeated string output_fields = 7;
* @param index The index of the value to return.
* @return The bytes of the outputFields at the given index.
*/
public com.google.protobuf.ByteString
getOutputFieldsBytes(int index) {
return outputFields_.getByteString(index);
}
public static final int GROUP_BY_FIELD_VALUE_FIELD_NUMBER = 8;
private io.milvus.grpc.FieldData groupByFieldValue_;
/**
* .milvus.proto.schema.FieldData group_by_field_value = 8;
* @return Whether the groupByFieldValue field is set.
*/
@java.lang.Override
public boolean hasGroupByFieldValue() {
return ((bitField0_ & 0x00000002) != 0);
}
/**
* .milvus.proto.schema.FieldData group_by_field_value = 8;
* @return The groupByFieldValue.
*/
@java.lang.Override
public io.milvus.grpc.FieldData getGroupByFieldValue() {
return groupByFieldValue_ == null ? io.milvus.grpc.FieldData.getDefaultInstance() : groupByFieldValue_;
}
/**
* .milvus.proto.schema.FieldData group_by_field_value = 8;
*/
@java.lang.Override
public io.milvus.grpc.FieldDataOrBuilder getGroupByFieldValueOrBuilder() {
return groupByFieldValue_ == null ? io.milvus.grpc.FieldData.getDefaultInstance() : groupByFieldValue_;
}
public static final int ALL_SEARCH_COUNT_FIELD_NUMBER = 9;
private long allSearchCount_ = 0L;
/**
* int64 all_search_count = 9;
* @return The allSearchCount.
*/
@java.lang.Override
public long getAllSearchCount() {
return allSearchCount_;
}
public static final int DISTANCES_FIELD_NUMBER = 10;
@SuppressWarnings("serial")
private com.google.protobuf.Internal.FloatList distances_ =
emptyFloatList();
/**
* repeated float distances = 10;
* @return A list containing the distances.
*/
@java.lang.Override
public java.util.List
getDistancesList() {
return distances_;
}
/**
* repeated float distances = 10;
* @return The count of distances.
*/
public int getDistancesCount() {
return distances_.size();
}
/**
* repeated float distances = 10;
* @param index The index of the element to return.
* @return The distances at the given index.
*/
public float getDistances(int index) {
return distances_.getFloat(index);
}
private int distancesMemoizedSerializedSize = -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 (numQueries_ != 0L) {
output.writeInt64(1, numQueries_);
}
if (topK_ != 0L) {
output.writeInt64(2, topK_);
}
for (int i = 0; i < fieldsData_.size(); i++) {
output.writeMessage(3, fieldsData_.get(i));
}
if (getScoresList().size() > 0) {
output.writeUInt32NoTag(34);
output.writeUInt32NoTag(scoresMemoizedSerializedSize);
}
for (int i = 0; i < scores_.size(); i++) {
output.writeFloatNoTag(scores_.getFloat(i));
}
if (((bitField0_ & 0x00000001) != 0)) {
output.writeMessage(5, getIds());
}
if (getTopksList().size() > 0) {
output.writeUInt32NoTag(50);
output.writeUInt32NoTag(topksMemoizedSerializedSize);
}
for (int i = 0; i < topks_.size(); i++) {
output.writeInt64NoTag(topks_.getLong(i));
}
for (int i = 0; i < outputFields_.size(); i++) {
com.google.protobuf.GeneratedMessageV3.writeString(output, 7, outputFields_.getRaw(i));
}
if (((bitField0_ & 0x00000002) != 0)) {
output.writeMessage(8, getGroupByFieldValue());
}
if (allSearchCount_ != 0L) {
output.writeInt64(9, allSearchCount_);
}
if (getDistancesList().size() > 0) {
output.writeUInt32NoTag(82);
output.writeUInt32NoTag(distancesMemoizedSerializedSize);
}
for (int i = 0; i < distances_.size(); i++) {
output.writeFloatNoTag(distances_.getFloat(i));
}
getUnknownFields().writeTo(output);
}
@java.lang.Override
public int getSerializedSize() {
int size = memoizedSize;
if (size != -1) return size;
size = 0;
if (numQueries_ != 0L) {
size += com.google.protobuf.CodedOutputStream
.computeInt64Size(1, numQueries_);
}
if (topK_ != 0L) {
size += com.google.protobuf.CodedOutputStream
.computeInt64Size(2, topK_);
}
for (int i = 0; i < fieldsData_.size(); i++) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(3, fieldsData_.get(i));
}
{
int dataSize = 0;
dataSize = 4 * getScoresList().size();
size += dataSize;
if (!getScoresList().isEmpty()) {
size += 1;
size += com.google.protobuf.CodedOutputStream
.computeInt32SizeNoTag(dataSize);
}
scoresMemoizedSerializedSize = dataSize;
}
if (((bitField0_ & 0x00000001) != 0)) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(5, getIds());
}
{
int dataSize = 0;
for (int i = 0; i < topks_.size(); i++) {
dataSize += com.google.protobuf.CodedOutputStream
.computeInt64SizeNoTag(topks_.getLong(i));
}
size += dataSize;
if (!getTopksList().isEmpty()) {
size += 1;
size += com.google.protobuf.CodedOutputStream
.computeInt32SizeNoTag(dataSize);
}
topksMemoizedSerializedSize = dataSize;
}
{
int dataSize = 0;
for (int i = 0; i < outputFields_.size(); i++) {
dataSize += computeStringSizeNoTag(outputFields_.getRaw(i));
}
size += dataSize;
size += 1 * getOutputFieldsList().size();
}
if (((bitField0_ & 0x00000002) != 0)) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(8, getGroupByFieldValue());
}
if (allSearchCount_ != 0L) {
size += com.google.protobuf.CodedOutputStream
.computeInt64Size(9, allSearchCount_);
}
{
int dataSize = 0;
dataSize = 4 * getDistancesList().size();
size += dataSize;
if (!getDistancesList().isEmpty()) {
size += 1;
size += com.google.protobuf.CodedOutputStream
.computeInt32SizeNoTag(dataSize);
}
distancesMemoizedSerializedSize = 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 io.milvus.grpc.SearchResultData)) {
return super.equals(obj);
}
io.milvus.grpc.SearchResultData other = (io.milvus.grpc.SearchResultData) obj;
if (getNumQueries()
!= other.getNumQueries()) return false;
if (getTopK()
!= other.getTopK()) return false;
if (!getFieldsDataList()
.equals(other.getFieldsDataList())) return false;
if (!getScoresList()
.equals(other.getScoresList())) return false;
if (hasIds() != other.hasIds()) return false;
if (hasIds()) {
if (!getIds()
.equals(other.getIds())) return false;
}
if (!getTopksList()
.equals(other.getTopksList())) return false;
if (!getOutputFieldsList()
.equals(other.getOutputFieldsList())) return false;
if (hasGroupByFieldValue() != other.hasGroupByFieldValue()) return false;
if (hasGroupByFieldValue()) {
if (!getGroupByFieldValue()
.equals(other.getGroupByFieldValue())) return false;
}
if (getAllSearchCount()
!= other.getAllSearchCount()) return false;
if (!getDistancesList()
.equals(other.getDistancesList())) 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) + NUM_QUERIES_FIELD_NUMBER;
hash = (53 * hash) + com.google.protobuf.Internal.hashLong(
getNumQueries());
hash = (37 * hash) + TOP_K_FIELD_NUMBER;
hash = (53 * hash) + com.google.protobuf.Internal.hashLong(
getTopK());
if (getFieldsDataCount() > 0) {
hash = (37 * hash) + FIELDS_DATA_FIELD_NUMBER;
hash = (53 * hash) + getFieldsDataList().hashCode();
}
if (getScoresCount() > 0) {
hash = (37 * hash) + SCORES_FIELD_NUMBER;
hash = (53 * hash) + getScoresList().hashCode();
}
if (hasIds()) {
hash = (37 * hash) + IDS_FIELD_NUMBER;
hash = (53 * hash) + getIds().hashCode();
}
if (getTopksCount() > 0) {
hash = (37 * hash) + TOPKS_FIELD_NUMBER;
hash = (53 * hash) + getTopksList().hashCode();
}
if (getOutputFieldsCount() > 0) {
hash = (37 * hash) + OUTPUT_FIELDS_FIELD_NUMBER;
hash = (53 * hash) + getOutputFieldsList().hashCode();
}
if (hasGroupByFieldValue()) {
hash = (37 * hash) + GROUP_BY_FIELD_VALUE_FIELD_NUMBER;
hash = (53 * hash) + getGroupByFieldValue().hashCode();
}
hash = (37 * hash) + ALL_SEARCH_COUNT_FIELD_NUMBER;
hash = (53 * hash) + com.google.protobuf.Internal.hashLong(
getAllSearchCount());
if (getDistancesCount() > 0) {
hash = (37 * hash) + DISTANCES_FIELD_NUMBER;
hash = (53 * hash) + getDistancesList().hashCode();
}
hash = (29 * hash) + getUnknownFields().hashCode();
memoizedHashCode = hash;
return hash;
}
public static io.milvus.grpc.SearchResultData parseFrom(
java.nio.ByteBuffer data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static io.milvus.grpc.SearchResultData parseFrom(
java.nio.ByteBuffer data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static io.milvus.grpc.SearchResultData parseFrom(
com.google.protobuf.ByteString data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static io.milvus.grpc.SearchResultData parseFrom(
com.google.protobuf.ByteString data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static io.milvus.grpc.SearchResultData parseFrom(byte[] data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static io.milvus.grpc.SearchResultData parseFrom(
byte[] data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static io.milvus.grpc.SearchResultData parseFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static io.milvus.grpc.SearchResultData 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 io.milvus.grpc.SearchResultData parseDelimitedFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input);
}
public static io.milvus.grpc.SearchResultData 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 io.milvus.grpc.SearchResultData parseFrom(
com.google.protobuf.CodedInputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static io.milvus.grpc.SearchResultData 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(io.milvus.grpc.SearchResultData 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 milvus.proto.schema.SearchResultData}
*/
public static final class Builder extends
com.google.protobuf.GeneratedMessageV3.Builder implements
// @@protoc_insertion_point(builder_implements:milvus.proto.schema.SearchResultData)
io.milvus.grpc.SearchResultDataOrBuilder {
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return io.milvus.grpc.SchemaProto.internal_static_milvus_proto_schema_SearchResultData_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return io.milvus.grpc.SchemaProto.internal_static_milvus_proto_schema_SearchResultData_fieldAccessorTable
.ensureFieldAccessorsInitialized(
io.milvus.grpc.SearchResultData.class, io.milvus.grpc.SearchResultData.Builder.class);
}
// Construct using io.milvus.grpc.SearchResultData.newBuilder()
private Builder() {
maybeForceBuilderInitialization();
}
private Builder(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
super(parent);
maybeForceBuilderInitialization();
}
private void maybeForceBuilderInitialization() {
if (com.google.protobuf.GeneratedMessageV3
.alwaysUseFieldBuilders) {
getFieldsDataFieldBuilder();
getIdsFieldBuilder();
getGroupByFieldValueFieldBuilder();
}
}
@java.lang.Override
public Builder clear() {
super.clear();
bitField0_ = 0;
numQueries_ = 0L;
topK_ = 0L;
if (fieldsDataBuilder_ == null) {
fieldsData_ = java.util.Collections.emptyList();
} else {
fieldsData_ = null;
fieldsDataBuilder_.clear();
}
bitField0_ = (bitField0_ & ~0x00000004);
scores_ = emptyFloatList();
ids_ = null;
if (idsBuilder_ != null) {
idsBuilder_.dispose();
idsBuilder_ = null;
}
topks_ = emptyLongList();
outputFields_ =
com.google.protobuf.LazyStringArrayList.emptyList();
groupByFieldValue_ = null;
if (groupByFieldValueBuilder_ != null) {
groupByFieldValueBuilder_.dispose();
groupByFieldValueBuilder_ = null;
}
allSearchCount_ = 0L;
distances_ = emptyFloatList();
return this;
}
@java.lang.Override
public com.google.protobuf.Descriptors.Descriptor
getDescriptorForType() {
return io.milvus.grpc.SchemaProto.internal_static_milvus_proto_schema_SearchResultData_descriptor;
}
@java.lang.Override
public io.milvus.grpc.SearchResultData getDefaultInstanceForType() {
return io.milvus.grpc.SearchResultData.getDefaultInstance();
}
@java.lang.Override
public io.milvus.grpc.SearchResultData build() {
io.milvus.grpc.SearchResultData result = buildPartial();
if (!result.isInitialized()) {
throw newUninitializedMessageException(result);
}
return result;
}
@java.lang.Override
public io.milvus.grpc.SearchResultData buildPartial() {
io.milvus.grpc.SearchResultData result = new io.milvus.grpc.SearchResultData(this);
buildPartialRepeatedFields(result);
if (bitField0_ != 0) { buildPartial0(result); }
onBuilt();
return result;
}
private void buildPartialRepeatedFields(io.milvus.grpc.SearchResultData result) {
if (fieldsDataBuilder_ == null) {
if (((bitField0_ & 0x00000004) != 0)) {
fieldsData_ = java.util.Collections.unmodifiableList(fieldsData_);
bitField0_ = (bitField0_ & ~0x00000004);
}
result.fieldsData_ = fieldsData_;
} else {
result.fieldsData_ = fieldsDataBuilder_.build();
}
}
private void buildPartial0(io.milvus.grpc.SearchResultData result) {
int from_bitField0_ = bitField0_;
if (((from_bitField0_ & 0x00000001) != 0)) {
result.numQueries_ = numQueries_;
}
if (((from_bitField0_ & 0x00000002) != 0)) {
result.topK_ = topK_;
}
if (((from_bitField0_ & 0x00000008) != 0)) {
scores_.makeImmutable();
result.scores_ = scores_;
}
int to_bitField0_ = 0;
if (((from_bitField0_ & 0x00000010) != 0)) {
result.ids_ = idsBuilder_ == null
? ids_
: idsBuilder_.build();
to_bitField0_ |= 0x00000001;
}
if (((from_bitField0_ & 0x00000020) != 0)) {
topks_.makeImmutable();
result.topks_ = topks_;
}
if (((from_bitField0_ & 0x00000040) != 0)) {
outputFields_.makeImmutable();
result.outputFields_ = outputFields_;
}
if (((from_bitField0_ & 0x00000080) != 0)) {
result.groupByFieldValue_ = groupByFieldValueBuilder_ == null
? groupByFieldValue_
: groupByFieldValueBuilder_.build();
to_bitField0_ |= 0x00000002;
}
if (((from_bitField0_ & 0x00000100) != 0)) {
result.allSearchCount_ = allSearchCount_;
}
if (((from_bitField0_ & 0x00000200) != 0)) {
distances_.makeImmutable();
result.distances_ = distances_;
}
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 io.milvus.grpc.SearchResultData) {
return mergeFrom((io.milvus.grpc.SearchResultData)other);
} else {
super.mergeFrom(other);
return this;
}
}
public Builder mergeFrom(io.milvus.grpc.SearchResultData other) {
if (other == io.milvus.grpc.SearchResultData.getDefaultInstance()) return this;
if (other.getNumQueries() != 0L) {
setNumQueries(other.getNumQueries());
}
if (other.getTopK() != 0L) {
setTopK(other.getTopK());
}
if (fieldsDataBuilder_ == null) {
if (!other.fieldsData_.isEmpty()) {
if (fieldsData_.isEmpty()) {
fieldsData_ = other.fieldsData_;
bitField0_ = (bitField0_ & ~0x00000004);
} else {
ensureFieldsDataIsMutable();
fieldsData_.addAll(other.fieldsData_);
}
onChanged();
}
} else {
if (!other.fieldsData_.isEmpty()) {
if (fieldsDataBuilder_.isEmpty()) {
fieldsDataBuilder_.dispose();
fieldsDataBuilder_ = null;
fieldsData_ = other.fieldsData_;
bitField0_ = (bitField0_ & ~0x00000004);
fieldsDataBuilder_ =
com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders ?
getFieldsDataFieldBuilder() : null;
} else {
fieldsDataBuilder_.addAllMessages(other.fieldsData_);
}
}
}
if (!other.scores_.isEmpty()) {
if (scores_.isEmpty()) {
scores_ = other.scores_;
scores_.makeImmutable();
bitField0_ |= 0x00000008;
} else {
ensureScoresIsMutable();
scores_.addAll(other.scores_);
}
onChanged();
}
if (other.hasIds()) {
mergeIds(other.getIds());
}
if (!other.topks_.isEmpty()) {
if (topks_.isEmpty()) {
topks_ = other.topks_;
topks_.makeImmutable();
bitField0_ |= 0x00000020;
} else {
ensureTopksIsMutable();
topks_.addAll(other.topks_);
}
onChanged();
}
if (!other.outputFields_.isEmpty()) {
if (outputFields_.isEmpty()) {
outputFields_ = other.outputFields_;
bitField0_ |= 0x00000040;
} else {
ensureOutputFieldsIsMutable();
outputFields_.addAll(other.outputFields_);
}
onChanged();
}
if (other.hasGroupByFieldValue()) {
mergeGroupByFieldValue(other.getGroupByFieldValue());
}
if (other.getAllSearchCount() != 0L) {
setAllSearchCount(other.getAllSearchCount());
}
if (!other.distances_.isEmpty()) {
if (distances_.isEmpty()) {
distances_ = other.distances_;
distances_.makeImmutable();
bitField0_ |= 0x00000200;
} else {
ensureDistancesIsMutable();
distances_.addAll(other.distances_);
}
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: {
numQueries_ = input.readInt64();
bitField0_ |= 0x00000001;
break;
} // case 8
case 16: {
topK_ = input.readInt64();
bitField0_ |= 0x00000002;
break;
} // case 16
case 26: {
io.milvus.grpc.FieldData m =
input.readMessage(
io.milvus.grpc.FieldData.parser(),
extensionRegistry);
if (fieldsDataBuilder_ == null) {
ensureFieldsDataIsMutable();
fieldsData_.add(m);
} else {
fieldsDataBuilder_.addMessage(m);
}
break;
} // case 26
case 37: {
float v = input.readFloat();
ensureScoresIsMutable();
scores_.addFloat(v);
break;
} // case 37
case 34: {
int length = input.readRawVarint32();
int limit = input.pushLimit(length);
int alloc = length > 4096 ? 4096 : length;
ensureScoresIsMutable(alloc / 4);
while (input.getBytesUntilLimit() > 0) {
scores_.addFloat(input.readFloat());
}
input.popLimit(limit);
break;
} // case 34
case 42: {
input.readMessage(
getIdsFieldBuilder().getBuilder(),
extensionRegistry);
bitField0_ |= 0x00000010;
break;
} // case 42
case 48: {
long v = input.readInt64();
ensureTopksIsMutable();
topks_.addLong(v);
break;
} // case 48
case 50: {
int length = input.readRawVarint32();
int limit = input.pushLimit(length);
ensureTopksIsMutable();
while (input.getBytesUntilLimit() > 0) {
topks_.addLong(input.readInt64());
}
input.popLimit(limit);
break;
} // case 50
case 58: {
java.lang.String s = input.readStringRequireUtf8();
ensureOutputFieldsIsMutable();
outputFields_.add(s);
break;
} // case 58
case 66: {
input.readMessage(
getGroupByFieldValueFieldBuilder().getBuilder(),
extensionRegistry);
bitField0_ |= 0x00000080;
break;
} // case 66
case 72: {
allSearchCount_ = input.readInt64();
bitField0_ |= 0x00000100;
break;
} // case 72
case 85: {
float v = input.readFloat();
ensureDistancesIsMutable();
distances_.addFloat(v);
break;
} // case 85
case 82: {
int length = input.readRawVarint32();
int limit = input.pushLimit(length);
int alloc = length > 4096 ? 4096 : length;
ensureDistancesIsMutable(alloc / 4);
while (input.getBytesUntilLimit() > 0) {
distances_.addFloat(input.readFloat());
}
input.popLimit(limit);
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 bitField0_;
private long numQueries_ ;
/**
* int64 num_queries = 1;
* @return The numQueries.
*/
@java.lang.Override
public long getNumQueries() {
return numQueries_;
}
/**
* int64 num_queries = 1;
* @param value The numQueries to set.
* @return This builder for chaining.
*/
public Builder setNumQueries(long value) {
numQueries_ = value;
bitField0_ |= 0x00000001;
onChanged();
return this;
}
/**
* int64 num_queries = 1;
* @return This builder for chaining.
*/
public Builder clearNumQueries() {
bitField0_ = (bitField0_ & ~0x00000001);
numQueries_ = 0L;
onChanged();
return this;
}
private long topK_ ;
/**
* int64 top_k = 2;
* @return The topK.
*/
@java.lang.Override
public long getTopK() {
return topK_;
}
/**
* int64 top_k = 2;
* @param value The topK to set.
* @return This builder for chaining.
*/
public Builder setTopK(long value) {
topK_ = value;
bitField0_ |= 0x00000002;
onChanged();
return this;
}
/**
* int64 top_k = 2;
* @return This builder for chaining.
*/
public Builder clearTopK() {
bitField0_ = (bitField0_ & ~0x00000002);
topK_ = 0L;
onChanged();
return this;
}
private java.util.List fieldsData_ =
java.util.Collections.emptyList();
private void ensureFieldsDataIsMutable() {
if (!((bitField0_ & 0x00000004) != 0)) {
fieldsData_ = new java.util.ArrayList(fieldsData_);
bitField0_ |= 0x00000004;
}
}
private com.google.protobuf.RepeatedFieldBuilderV3<
io.milvus.grpc.FieldData, io.milvus.grpc.FieldData.Builder, io.milvus.grpc.FieldDataOrBuilder> fieldsDataBuilder_;
/**
* repeated .milvus.proto.schema.FieldData fields_data = 3;
*/
public java.util.List getFieldsDataList() {
if (fieldsDataBuilder_ == null) {
return java.util.Collections.unmodifiableList(fieldsData_);
} else {
return fieldsDataBuilder_.getMessageList();
}
}
/**
* repeated .milvus.proto.schema.FieldData fields_data = 3;
*/
public int getFieldsDataCount() {
if (fieldsDataBuilder_ == null) {
return fieldsData_.size();
} else {
return fieldsDataBuilder_.getCount();
}
}
/**
* repeated .milvus.proto.schema.FieldData fields_data = 3;
*/
public io.milvus.grpc.FieldData getFieldsData(int index) {
if (fieldsDataBuilder_ == null) {
return fieldsData_.get(index);
} else {
return fieldsDataBuilder_.getMessage(index);
}
}
/**
* repeated .milvus.proto.schema.FieldData fields_data = 3;
*/
public Builder setFieldsData(
int index, io.milvus.grpc.FieldData value) {
if (fieldsDataBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
ensureFieldsDataIsMutable();
fieldsData_.set(index, value);
onChanged();
} else {
fieldsDataBuilder_.setMessage(index, value);
}
return this;
}
/**
* repeated .milvus.proto.schema.FieldData fields_data = 3;
*/
public Builder setFieldsData(
int index, io.milvus.grpc.FieldData.Builder builderForValue) {
if (fieldsDataBuilder_ == null) {
ensureFieldsDataIsMutable();
fieldsData_.set(index, builderForValue.build());
onChanged();
} else {
fieldsDataBuilder_.setMessage(index, builderForValue.build());
}
return this;
}
/**
* repeated .milvus.proto.schema.FieldData fields_data = 3;
*/
public Builder addFieldsData(io.milvus.grpc.FieldData value) {
if (fieldsDataBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
ensureFieldsDataIsMutable();
fieldsData_.add(value);
onChanged();
} else {
fieldsDataBuilder_.addMessage(value);
}
return this;
}
/**
* repeated .milvus.proto.schema.FieldData fields_data = 3;
*/
public Builder addFieldsData(
int index, io.milvus.grpc.FieldData value) {
if (fieldsDataBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
ensureFieldsDataIsMutable();
fieldsData_.add(index, value);
onChanged();
} else {
fieldsDataBuilder_.addMessage(index, value);
}
return this;
}
/**
* repeated .milvus.proto.schema.FieldData fields_data = 3;
*/
public Builder addFieldsData(
io.milvus.grpc.FieldData.Builder builderForValue) {
if (fieldsDataBuilder_ == null) {
ensureFieldsDataIsMutable();
fieldsData_.add(builderForValue.build());
onChanged();
} else {
fieldsDataBuilder_.addMessage(builderForValue.build());
}
return this;
}
/**
* repeated .milvus.proto.schema.FieldData fields_data = 3;
*/
public Builder addFieldsData(
int index, io.milvus.grpc.FieldData.Builder builderForValue) {
if (fieldsDataBuilder_ == null) {
ensureFieldsDataIsMutable();
fieldsData_.add(index, builderForValue.build());
onChanged();
} else {
fieldsDataBuilder_.addMessage(index, builderForValue.build());
}
return this;
}
/**
* repeated .milvus.proto.schema.FieldData fields_data = 3;
*/
public Builder addAllFieldsData(
java.lang.Iterable extends io.milvus.grpc.FieldData> values) {
if (fieldsDataBuilder_ == null) {
ensureFieldsDataIsMutable();
com.google.protobuf.AbstractMessageLite.Builder.addAll(
values, fieldsData_);
onChanged();
} else {
fieldsDataBuilder_.addAllMessages(values);
}
return this;
}
/**
* repeated .milvus.proto.schema.FieldData fields_data = 3;
*/
public Builder clearFieldsData() {
if (fieldsDataBuilder_ == null) {
fieldsData_ = java.util.Collections.emptyList();
bitField0_ = (bitField0_ & ~0x00000004);
onChanged();
} else {
fieldsDataBuilder_.clear();
}
return this;
}
/**
* repeated .milvus.proto.schema.FieldData fields_data = 3;
*/
public Builder removeFieldsData(int index) {
if (fieldsDataBuilder_ == null) {
ensureFieldsDataIsMutable();
fieldsData_.remove(index);
onChanged();
} else {
fieldsDataBuilder_.remove(index);
}
return this;
}
/**
* repeated .milvus.proto.schema.FieldData fields_data = 3;
*/
public io.milvus.grpc.FieldData.Builder getFieldsDataBuilder(
int index) {
return getFieldsDataFieldBuilder().getBuilder(index);
}
/**
* repeated .milvus.proto.schema.FieldData fields_data = 3;
*/
public io.milvus.grpc.FieldDataOrBuilder getFieldsDataOrBuilder(
int index) {
if (fieldsDataBuilder_ == null) {
return fieldsData_.get(index); } else {
return fieldsDataBuilder_.getMessageOrBuilder(index);
}
}
/**
* repeated .milvus.proto.schema.FieldData fields_data = 3;
*/
public java.util.List extends io.milvus.grpc.FieldDataOrBuilder>
getFieldsDataOrBuilderList() {
if (fieldsDataBuilder_ != null) {
return fieldsDataBuilder_.getMessageOrBuilderList();
} else {
return java.util.Collections.unmodifiableList(fieldsData_);
}
}
/**
* repeated .milvus.proto.schema.FieldData fields_data = 3;
*/
public io.milvus.grpc.FieldData.Builder addFieldsDataBuilder() {
return getFieldsDataFieldBuilder().addBuilder(
io.milvus.grpc.FieldData.getDefaultInstance());
}
/**
* repeated .milvus.proto.schema.FieldData fields_data = 3;
*/
public io.milvus.grpc.FieldData.Builder addFieldsDataBuilder(
int index) {
return getFieldsDataFieldBuilder().addBuilder(
index, io.milvus.grpc.FieldData.getDefaultInstance());
}
/**
* repeated .milvus.proto.schema.FieldData fields_data = 3;
*/
public java.util.List
getFieldsDataBuilderList() {
return getFieldsDataFieldBuilder().getBuilderList();
}
private com.google.protobuf.RepeatedFieldBuilderV3<
io.milvus.grpc.FieldData, io.milvus.grpc.FieldData.Builder, io.milvus.grpc.FieldDataOrBuilder>
getFieldsDataFieldBuilder() {
if (fieldsDataBuilder_ == null) {
fieldsDataBuilder_ = new com.google.protobuf.RepeatedFieldBuilderV3<
io.milvus.grpc.FieldData, io.milvus.grpc.FieldData.Builder, io.milvus.grpc.FieldDataOrBuilder>(
fieldsData_,
((bitField0_ & 0x00000004) != 0),
getParentForChildren(),
isClean());
fieldsData_ = null;
}
return fieldsDataBuilder_;
}
private com.google.protobuf.Internal.FloatList scores_ = emptyFloatList();
private void ensureScoresIsMutable() {
if (!scores_.isModifiable()) {
scores_ = makeMutableCopy(scores_);
}
bitField0_ |= 0x00000008;
}
private void ensureScoresIsMutable(int capacity) {
if (!scores_.isModifiable()) {
scores_ = makeMutableCopy(scores_, capacity);
}
bitField0_ |= 0x00000008;
}
/**
* repeated float scores = 4;
* @return A list containing the scores.
*/
public java.util.List
getScoresList() {
scores_.makeImmutable();
return scores_;
}
/**
* repeated float scores = 4;
* @return The count of scores.
*/
public int getScoresCount() {
return scores_.size();
}
/**
* repeated float scores = 4;
* @param index The index of the element to return.
* @return The scores at the given index.
*/
public float getScores(int index) {
return scores_.getFloat(index);
}
/**
* repeated float scores = 4;
* @param index The index to set the value at.
* @param value The scores to set.
* @return This builder for chaining.
*/
public Builder setScores(
int index, float value) {
ensureScoresIsMutable();
scores_.setFloat(index, value);
bitField0_ |= 0x00000008;
onChanged();
return this;
}
/**
* repeated float scores = 4;
* @param value The scores to add.
* @return This builder for chaining.
*/
public Builder addScores(float value) {
ensureScoresIsMutable();
scores_.addFloat(value);
bitField0_ |= 0x00000008;
onChanged();
return this;
}
/**
* repeated float scores = 4;
* @param values The scores to add.
* @return This builder for chaining.
*/
public Builder addAllScores(
java.lang.Iterable extends java.lang.Float> values) {
ensureScoresIsMutable();
com.google.protobuf.AbstractMessageLite.Builder.addAll(
values, scores_);
bitField0_ |= 0x00000008;
onChanged();
return this;
}
/**
* repeated float scores = 4;
* @return This builder for chaining.
*/
public Builder clearScores() {
scores_ = emptyFloatList();
bitField0_ = (bitField0_ & ~0x00000008);
onChanged();
return this;
}
private io.milvus.grpc.IDs ids_;
private com.google.protobuf.SingleFieldBuilderV3<
io.milvus.grpc.IDs, io.milvus.grpc.IDs.Builder, io.milvus.grpc.IDsOrBuilder> idsBuilder_;
/**
* .milvus.proto.schema.IDs ids = 5;
* @return Whether the ids field is set.
*/
public boolean hasIds() {
return ((bitField0_ & 0x00000010) != 0);
}
/**
* .milvus.proto.schema.IDs ids = 5;
* @return The ids.
*/
public io.milvus.grpc.IDs getIds() {
if (idsBuilder_ == null) {
return ids_ == null ? io.milvus.grpc.IDs.getDefaultInstance() : ids_;
} else {
return idsBuilder_.getMessage();
}
}
/**
* .milvus.proto.schema.IDs ids = 5;
*/
public Builder setIds(io.milvus.grpc.IDs value) {
if (idsBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
ids_ = value;
} else {
idsBuilder_.setMessage(value);
}
bitField0_ |= 0x00000010;
onChanged();
return this;
}
/**
* .milvus.proto.schema.IDs ids = 5;
*/
public Builder setIds(
io.milvus.grpc.IDs.Builder builderForValue) {
if (idsBuilder_ == null) {
ids_ = builderForValue.build();
} else {
idsBuilder_.setMessage(builderForValue.build());
}
bitField0_ |= 0x00000010;
onChanged();
return this;
}
/**
* .milvus.proto.schema.IDs ids = 5;
*/
public Builder mergeIds(io.milvus.grpc.IDs value) {
if (idsBuilder_ == null) {
if (((bitField0_ & 0x00000010) != 0) &&
ids_ != null &&
ids_ != io.milvus.grpc.IDs.getDefaultInstance()) {
getIdsBuilder().mergeFrom(value);
} else {
ids_ = value;
}
} else {
idsBuilder_.mergeFrom(value);
}
if (ids_ != null) {
bitField0_ |= 0x00000010;
onChanged();
}
return this;
}
/**
* .milvus.proto.schema.IDs ids = 5;
*/
public Builder clearIds() {
bitField0_ = (bitField0_ & ~0x00000010);
ids_ = null;
if (idsBuilder_ != null) {
idsBuilder_.dispose();
idsBuilder_ = null;
}
onChanged();
return this;
}
/**
* .milvus.proto.schema.IDs ids = 5;
*/
public io.milvus.grpc.IDs.Builder getIdsBuilder() {
bitField0_ |= 0x00000010;
onChanged();
return getIdsFieldBuilder().getBuilder();
}
/**
* .milvus.proto.schema.IDs ids = 5;
*/
public io.milvus.grpc.IDsOrBuilder getIdsOrBuilder() {
if (idsBuilder_ != null) {
return idsBuilder_.getMessageOrBuilder();
} else {
return ids_ == null ?
io.milvus.grpc.IDs.getDefaultInstance() : ids_;
}
}
/**
* .milvus.proto.schema.IDs ids = 5;
*/
private com.google.protobuf.SingleFieldBuilderV3<
io.milvus.grpc.IDs, io.milvus.grpc.IDs.Builder, io.milvus.grpc.IDsOrBuilder>
getIdsFieldBuilder() {
if (idsBuilder_ == null) {
idsBuilder_ = new com.google.protobuf.SingleFieldBuilderV3<
io.milvus.grpc.IDs, io.milvus.grpc.IDs.Builder, io.milvus.grpc.IDsOrBuilder>(
getIds(),
getParentForChildren(),
isClean());
ids_ = null;
}
return idsBuilder_;
}
private com.google.protobuf.Internal.LongList topks_ = emptyLongList();
private void ensureTopksIsMutable() {
if (!topks_.isModifiable()) {
topks_ = makeMutableCopy(topks_);
}
bitField0_ |= 0x00000020;
}
/**
* repeated int64 topks = 6;
* @return A list containing the topks.
*/
public java.util.List
getTopksList() {
topks_.makeImmutable();
return topks_;
}
/**
* repeated int64 topks = 6;
* @return The count of topks.
*/
public int getTopksCount() {
return topks_.size();
}
/**
* repeated int64 topks = 6;
* @param index The index of the element to return.
* @return The topks at the given index.
*/
public long getTopks(int index) {
return topks_.getLong(index);
}
/**
* repeated int64 topks = 6;
* @param index The index to set the value at.
* @param value The topks to set.
* @return This builder for chaining.
*/
public Builder setTopks(
int index, long value) {
ensureTopksIsMutable();
topks_.setLong(index, value);
bitField0_ |= 0x00000020;
onChanged();
return this;
}
/**
* repeated int64 topks = 6;
* @param value The topks to add.
* @return This builder for chaining.
*/
public Builder addTopks(long value) {
ensureTopksIsMutable();
topks_.addLong(value);
bitField0_ |= 0x00000020;
onChanged();
return this;
}
/**
* repeated int64 topks = 6;
* @param values The topks to add.
* @return This builder for chaining.
*/
public Builder addAllTopks(
java.lang.Iterable extends java.lang.Long> values) {
ensureTopksIsMutable();
com.google.protobuf.AbstractMessageLite.Builder.addAll(
values, topks_);
bitField0_ |= 0x00000020;
onChanged();
return this;
}
/**
* repeated int64 topks = 6;
* @return This builder for chaining.
*/
public Builder clearTopks() {
topks_ = emptyLongList();
bitField0_ = (bitField0_ & ~0x00000020);
onChanged();
return this;
}
private com.google.protobuf.LazyStringArrayList outputFields_ =
com.google.protobuf.LazyStringArrayList.emptyList();
private void ensureOutputFieldsIsMutable() {
if (!outputFields_.isModifiable()) {
outputFields_ = new com.google.protobuf.LazyStringArrayList(outputFields_);
}
bitField0_ |= 0x00000040;
}
/**
* repeated string output_fields = 7;
* @return A list containing the outputFields.
*/
public com.google.protobuf.ProtocolStringList
getOutputFieldsList() {
outputFields_.makeImmutable();
return outputFields_;
}
/**
* repeated string output_fields = 7;
* @return The count of outputFields.
*/
public int getOutputFieldsCount() {
return outputFields_.size();
}
/**
* repeated string output_fields = 7;
* @param index The index of the element to return.
* @return The outputFields at the given index.
*/
public java.lang.String getOutputFields(int index) {
return outputFields_.get(index);
}
/**
* repeated string output_fields = 7;
* @param index The index of the value to return.
* @return The bytes of the outputFields at the given index.
*/
public com.google.protobuf.ByteString
getOutputFieldsBytes(int index) {
return outputFields_.getByteString(index);
}
/**
* repeated string output_fields = 7;
* @param index The index to set the value at.
* @param value The outputFields to set.
* @return This builder for chaining.
*/
public Builder setOutputFields(
int index, java.lang.String value) {
if (value == null) { throw new NullPointerException(); }
ensureOutputFieldsIsMutable();
outputFields_.set(index, value);
bitField0_ |= 0x00000040;
onChanged();
return this;
}
/**
* repeated string output_fields = 7;
* @param value The outputFields to add.
* @return This builder for chaining.
*/
public Builder addOutputFields(
java.lang.String value) {
if (value == null) { throw new NullPointerException(); }
ensureOutputFieldsIsMutable();
outputFields_.add(value);
bitField0_ |= 0x00000040;
onChanged();
return this;
}
/**
* repeated string output_fields = 7;
* @param values The outputFields to add.
* @return This builder for chaining.
*/
public Builder addAllOutputFields(
java.lang.Iterable values) {
ensureOutputFieldsIsMutable();
com.google.protobuf.AbstractMessageLite.Builder.addAll(
values, outputFields_);
bitField0_ |= 0x00000040;
onChanged();
return this;
}
/**
* repeated string output_fields = 7;
* @return This builder for chaining.
*/
public Builder clearOutputFields() {
outputFields_ =
com.google.protobuf.LazyStringArrayList.emptyList();
bitField0_ = (bitField0_ & ~0x00000040);;
onChanged();
return this;
}
/**
* repeated string output_fields = 7;
* @param value The bytes of the outputFields to add.
* @return This builder for chaining.
*/
public Builder addOutputFieldsBytes(
com.google.protobuf.ByteString value) {
if (value == null) { throw new NullPointerException(); }
checkByteStringIsUtf8(value);
ensureOutputFieldsIsMutable();
outputFields_.add(value);
bitField0_ |= 0x00000040;
onChanged();
return this;
}
private io.milvus.grpc.FieldData groupByFieldValue_;
private com.google.protobuf.SingleFieldBuilderV3<
io.milvus.grpc.FieldData, io.milvus.grpc.FieldData.Builder, io.milvus.grpc.FieldDataOrBuilder> groupByFieldValueBuilder_;
/**
* .milvus.proto.schema.FieldData group_by_field_value = 8;
* @return Whether the groupByFieldValue field is set.
*/
public boolean hasGroupByFieldValue() {
return ((bitField0_ & 0x00000080) != 0);
}
/**
* .milvus.proto.schema.FieldData group_by_field_value = 8;
* @return The groupByFieldValue.
*/
public io.milvus.grpc.FieldData getGroupByFieldValue() {
if (groupByFieldValueBuilder_ == null) {
return groupByFieldValue_ == null ? io.milvus.grpc.FieldData.getDefaultInstance() : groupByFieldValue_;
} else {
return groupByFieldValueBuilder_.getMessage();
}
}
/**
* .milvus.proto.schema.FieldData group_by_field_value = 8;
*/
public Builder setGroupByFieldValue(io.milvus.grpc.FieldData value) {
if (groupByFieldValueBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
groupByFieldValue_ = value;
} else {
groupByFieldValueBuilder_.setMessage(value);
}
bitField0_ |= 0x00000080;
onChanged();
return this;
}
/**
* .milvus.proto.schema.FieldData group_by_field_value = 8;
*/
public Builder setGroupByFieldValue(
io.milvus.grpc.FieldData.Builder builderForValue) {
if (groupByFieldValueBuilder_ == null) {
groupByFieldValue_ = builderForValue.build();
} else {
groupByFieldValueBuilder_.setMessage(builderForValue.build());
}
bitField0_ |= 0x00000080;
onChanged();
return this;
}
/**
* .milvus.proto.schema.FieldData group_by_field_value = 8;
*/
public Builder mergeGroupByFieldValue(io.milvus.grpc.FieldData value) {
if (groupByFieldValueBuilder_ == null) {
if (((bitField0_ & 0x00000080) != 0) &&
groupByFieldValue_ != null &&
groupByFieldValue_ != io.milvus.grpc.FieldData.getDefaultInstance()) {
getGroupByFieldValueBuilder().mergeFrom(value);
} else {
groupByFieldValue_ = value;
}
} else {
groupByFieldValueBuilder_.mergeFrom(value);
}
if (groupByFieldValue_ != null) {
bitField0_ |= 0x00000080;
onChanged();
}
return this;
}
/**
* .milvus.proto.schema.FieldData group_by_field_value = 8;
*/
public Builder clearGroupByFieldValue() {
bitField0_ = (bitField0_ & ~0x00000080);
groupByFieldValue_ = null;
if (groupByFieldValueBuilder_ != null) {
groupByFieldValueBuilder_.dispose();
groupByFieldValueBuilder_ = null;
}
onChanged();
return this;
}
/**
* .milvus.proto.schema.FieldData group_by_field_value = 8;
*/
public io.milvus.grpc.FieldData.Builder getGroupByFieldValueBuilder() {
bitField0_ |= 0x00000080;
onChanged();
return getGroupByFieldValueFieldBuilder().getBuilder();
}
/**
* .milvus.proto.schema.FieldData group_by_field_value = 8;
*/
public io.milvus.grpc.FieldDataOrBuilder getGroupByFieldValueOrBuilder() {
if (groupByFieldValueBuilder_ != null) {
return groupByFieldValueBuilder_.getMessageOrBuilder();
} else {
return groupByFieldValue_ == null ?
io.milvus.grpc.FieldData.getDefaultInstance() : groupByFieldValue_;
}
}
/**
* .milvus.proto.schema.FieldData group_by_field_value = 8;
*/
private com.google.protobuf.SingleFieldBuilderV3<
io.milvus.grpc.FieldData, io.milvus.grpc.FieldData.Builder, io.milvus.grpc.FieldDataOrBuilder>
getGroupByFieldValueFieldBuilder() {
if (groupByFieldValueBuilder_ == null) {
groupByFieldValueBuilder_ = new com.google.protobuf.SingleFieldBuilderV3<
io.milvus.grpc.FieldData, io.milvus.grpc.FieldData.Builder, io.milvus.grpc.FieldDataOrBuilder>(
getGroupByFieldValue(),
getParentForChildren(),
isClean());
groupByFieldValue_ = null;
}
return groupByFieldValueBuilder_;
}
private long allSearchCount_ ;
/**
* int64 all_search_count = 9;
* @return The allSearchCount.
*/
@java.lang.Override
public long getAllSearchCount() {
return allSearchCount_;
}
/**
* int64 all_search_count = 9;
* @param value The allSearchCount to set.
* @return This builder for chaining.
*/
public Builder setAllSearchCount(long value) {
allSearchCount_ = value;
bitField0_ |= 0x00000100;
onChanged();
return this;
}
/**
* int64 all_search_count = 9;
* @return This builder for chaining.
*/
public Builder clearAllSearchCount() {
bitField0_ = (bitField0_ & ~0x00000100);
allSearchCount_ = 0L;
onChanged();
return this;
}
private com.google.protobuf.Internal.FloatList distances_ = emptyFloatList();
private void ensureDistancesIsMutable() {
if (!distances_.isModifiable()) {
distances_ = makeMutableCopy(distances_);
}
bitField0_ |= 0x00000200;
}
private void ensureDistancesIsMutable(int capacity) {
if (!distances_.isModifiable()) {
distances_ = makeMutableCopy(distances_, capacity);
}
bitField0_ |= 0x00000200;
}
/**
* repeated float distances = 10;
* @return A list containing the distances.
*/
public java.util.List
getDistancesList() {
distances_.makeImmutable();
return distances_;
}
/**
* repeated float distances = 10;
* @return The count of distances.
*/
public int getDistancesCount() {
return distances_.size();
}
/**
* repeated float distances = 10;
* @param index The index of the element to return.
* @return The distances at the given index.
*/
public float getDistances(int index) {
return distances_.getFloat(index);
}
/**
* repeated float distances = 10;
* @param index The index to set the value at.
* @param value The distances to set.
* @return This builder for chaining.
*/
public Builder setDistances(
int index, float value) {
ensureDistancesIsMutable();
distances_.setFloat(index, value);
bitField0_ |= 0x00000200;
onChanged();
return this;
}
/**
* repeated float distances = 10;
* @param value The distances to add.
* @return This builder for chaining.
*/
public Builder addDistances(float value) {
ensureDistancesIsMutable();
distances_.addFloat(value);
bitField0_ |= 0x00000200;
onChanged();
return this;
}
/**
* repeated float distances = 10;
* @param values The distances to add.
* @return This builder for chaining.
*/
public Builder addAllDistances(
java.lang.Iterable extends java.lang.Float> values) {
ensureDistancesIsMutable();
com.google.protobuf.AbstractMessageLite.Builder.addAll(
values, distances_);
bitField0_ |= 0x00000200;
onChanged();
return this;
}
/**
* repeated float distances = 10;
* @return This builder for chaining.
*/
public Builder clearDistances() {
distances_ = emptyFloatList();
bitField0_ = (bitField0_ & ~0x00000200);
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:milvus.proto.schema.SearchResultData)
}
// @@protoc_insertion_point(class_scope:milvus.proto.schema.SearchResultData)
private static final io.milvus.grpc.SearchResultData DEFAULT_INSTANCE;
static {
DEFAULT_INSTANCE = new io.milvus.grpc.SearchResultData();
}
public static io.milvus.grpc.SearchResultData getDefaultInstance() {
return DEFAULT_INSTANCE;
}
private static final com.google.protobuf.Parser
PARSER = new com.google.protobuf.AbstractParser() {
@java.lang.Override
public SearchResultData 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 io.milvus.grpc.SearchResultData getDefaultInstanceForType() {
return DEFAULT_INSTANCE;
}
}