com.yelp.nrtsearch.server.grpc.BooleanQuery Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of clientlib Show documentation
Show all versions of clientlib Show documentation
GRPC Clientlib for nrtSearch
// Generated by the protocol buffer compiler. DO NOT EDIT!
// source: yelp/nrtsearch/search.proto
// Protobuf Java Version: 3.25.3
package com.yelp.nrtsearch.server.grpc;
/**
*
* A query that matches documents using boolean combinations of other queries.
*
*
* Protobuf type {@code luceneserver.BooleanQuery}
*/
public final class BooleanQuery extends
com.google.protobuf.GeneratedMessageV3 implements
// @@protoc_insertion_point(message_implements:luceneserver.BooleanQuery)
BooleanQueryOrBuilder {
private static final long serialVersionUID = 0L;
// Use BooleanQuery.newBuilder() to construct.
private BooleanQuery(com.google.protobuf.GeneratedMessageV3.Builder> builder) {
super(builder);
}
private BooleanQuery() {
clauses_ = java.util.Collections.emptyList();
}
@java.lang.Override
@SuppressWarnings({"unused"})
protected java.lang.Object newInstance(
UnusedPrivateParameter unused) {
return new BooleanQuery();
}
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return com.yelp.nrtsearch.server.grpc.SearchResponseProto.internal_static_luceneserver_BooleanQuery_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return com.yelp.nrtsearch.server.grpc.SearchResponseProto.internal_static_luceneserver_BooleanQuery_fieldAccessorTable
.ensureFieldAccessorsInitialized(
com.yelp.nrtsearch.server.grpc.BooleanQuery.class, com.yelp.nrtsearch.server.grpc.BooleanQuery.Builder.class);
}
public static final int CLAUSES_FIELD_NUMBER = 1;
@SuppressWarnings("serial")
private java.util.List clauses_;
/**
*
* Clauses for a boolean query.
*
*
* repeated .luceneserver.BooleanClause clauses = 1;
*/
@java.lang.Override
public java.util.List getClausesList() {
return clauses_;
}
/**
*
* Clauses for a boolean query.
*
*
* repeated .luceneserver.BooleanClause clauses = 1;
*/
@java.lang.Override
public java.util.List extends com.yelp.nrtsearch.server.grpc.BooleanClauseOrBuilder>
getClausesOrBuilderList() {
return clauses_;
}
/**
*
* Clauses for a boolean query.
*
*
* repeated .luceneserver.BooleanClause clauses = 1;
*/
@java.lang.Override
public int getClausesCount() {
return clauses_.size();
}
/**
*
* Clauses for a boolean query.
*
*
* repeated .luceneserver.BooleanClause clauses = 1;
*/
@java.lang.Override
public com.yelp.nrtsearch.server.grpc.BooleanClause getClauses(int index) {
return clauses_.get(index);
}
/**
*
* Clauses for a boolean query.
*
*
* repeated .luceneserver.BooleanClause clauses = 1;
*/
@java.lang.Override
public com.yelp.nrtsearch.server.grpc.BooleanClauseOrBuilder getClausesOrBuilder(
int index) {
return clauses_.get(index);
}
public static final int MINIMUMNUMBERSHOULDMATCH_FIELD_NUMBER = 2;
private int minimumNumberShouldMatch_ = 0;
/**
*
* Minimum number of optional clauses that must match.
*
*
* int32 minimumNumberShouldMatch = 2;
* @return The minimumNumberShouldMatch.
*/
@java.lang.Override
public int getMinimumNumberShouldMatch() {
return minimumNumberShouldMatch_;
}
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 < clauses_.size(); i++) {
output.writeMessage(1, clauses_.get(i));
}
if (minimumNumberShouldMatch_ != 0) {
output.writeInt32(2, minimumNumberShouldMatch_);
}
getUnknownFields().writeTo(output);
}
@java.lang.Override
public int getSerializedSize() {
int size = memoizedSize;
if (size != -1) return size;
size = 0;
for (int i = 0; i < clauses_.size(); i++) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(1, clauses_.get(i));
}
if (minimumNumberShouldMatch_ != 0) {
size += com.google.protobuf.CodedOutputStream
.computeInt32Size(2, minimumNumberShouldMatch_);
}
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 com.yelp.nrtsearch.server.grpc.BooleanQuery)) {
return super.equals(obj);
}
com.yelp.nrtsearch.server.grpc.BooleanQuery other = (com.yelp.nrtsearch.server.grpc.BooleanQuery) obj;
if (!getClausesList()
.equals(other.getClausesList())) return false;
if (getMinimumNumberShouldMatch()
!= other.getMinimumNumberShouldMatch()) 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 (getClausesCount() > 0) {
hash = (37 * hash) + CLAUSES_FIELD_NUMBER;
hash = (53 * hash) + getClausesList().hashCode();
}
hash = (37 * hash) + MINIMUMNUMBERSHOULDMATCH_FIELD_NUMBER;
hash = (53 * hash) + getMinimumNumberShouldMatch();
hash = (29 * hash) + getUnknownFields().hashCode();
memoizedHashCode = hash;
return hash;
}
public static com.yelp.nrtsearch.server.grpc.BooleanQuery parseFrom(
java.nio.ByteBuffer data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static com.yelp.nrtsearch.server.grpc.BooleanQuery parseFrom(
java.nio.ByteBuffer data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static com.yelp.nrtsearch.server.grpc.BooleanQuery parseFrom(
com.google.protobuf.ByteString data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static com.yelp.nrtsearch.server.grpc.BooleanQuery parseFrom(
com.google.protobuf.ByteString data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static com.yelp.nrtsearch.server.grpc.BooleanQuery parseFrom(byte[] data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static com.yelp.nrtsearch.server.grpc.BooleanQuery parseFrom(
byte[] data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static com.yelp.nrtsearch.server.grpc.BooleanQuery parseFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static com.yelp.nrtsearch.server.grpc.BooleanQuery 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 com.yelp.nrtsearch.server.grpc.BooleanQuery parseDelimitedFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input);
}
public static com.yelp.nrtsearch.server.grpc.BooleanQuery 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 com.yelp.nrtsearch.server.grpc.BooleanQuery parseFrom(
com.google.protobuf.CodedInputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static com.yelp.nrtsearch.server.grpc.BooleanQuery 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(com.yelp.nrtsearch.server.grpc.BooleanQuery 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;
}
/**
*
* A query that matches documents using boolean combinations of other queries.
*
*
* Protobuf type {@code luceneserver.BooleanQuery}
*/
public static final class Builder extends
com.google.protobuf.GeneratedMessageV3.Builder implements
// @@protoc_insertion_point(builder_implements:luceneserver.BooleanQuery)
com.yelp.nrtsearch.server.grpc.BooleanQueryOrBuilder {
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return com.yelp.nrtsearch.server.grpc.SearchResponseProto.internal_static_luceneserver_BooleanQuery_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return com.yelp.nrtsearch.server.grpc.SearchResponseProto.internal_static_luceneserver_BooleanQuery_fieldAccessorTable
.ensureFieldAccessorsInitialized(
com.yelp.nrtsearch.server.grpc.BooleanQuery.class, com.yelp.nrtsearch.server.grpc.BooleanQuery.Builder.class);
}
// Construct using com.yelp.nrtsearch.server.grpc.BooleanQuery.newBuilder()
private Builder() {
}
private Builder(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
super(parent);
}
@java.lang.Override
public Builder clear() {
super.clear();
bitField0_ = 0;
if (clausesBuilder_ == null) {
clauses_ = java.util.Collections.emptyList();
} else {
clauses_ = null;
clausesBuilder_.clear();
}
bitField0_ = (bitField0_ & ~0x00000001);
minimumNumberShouldMatch_ = 0;
return this;
}
@java.lang.Override
public com.google.protobuf.Descriptors.Descriptor
getDescriptorForType() {
return com.yelp.nrtsearch.server.grpc.SearchResponseProto.internal_static_luceneserver_BooleanQuery_descriptor;
}
@java.lang.Override
public com.yelp.nrtsearch.server.grpc.BooleanQuery getDefaultInstanceForType() {
return com.yelp.nrtsearch.server.grpc.BooleanQuery.getDefaultInstance();
}
@java.lang.Override
public com.yelp.nrtsearch.server.grpc.BooleanQuery build() {
com.yelp.nrtsearch.server.grpc.BooleanQuery result = buildPartial();
if (!result.isInitialized()) {
throw newUninitializedMessageException(result);
}
return result;
}
@java.lang.Override
public com.yelp.nrtsearch.server.grpc.BooleanQuery buildPartial() {
com.yelp.nrtsearch.server.grpc.BooleanQuery result = new com.yelp.nrtsearch.server.grpc.BooleanQuery(this);
buildPartialRepeatedFields(result);
if (bitField0_ != 0) { buildPartial0(result); }
onBuilt();
return result;
}
private void buildPartialRepeatedFields(com.yelp.nrtsearch.server.grpc.BooleanQuery result) {
if (clausesBuilder_ == null) {
if (((bitField0_ & 0x00000001) != 0)) {
clauses_ = java.util.Collections.unmodifiableList(clauses_);
bitField0_ = (bitField0_ & ~0x00000001);
}
result.clauses_ = clauses_;
} else {
result.clauses_ = clausesBuilder_.build();
}
}
private void buildPartial0(com.yelp.nrtsearch.server.grpc.BooleanQuery result) {
int from_bitField0_ = bitField0_;
if (((from_bitField0_ & 0x00000002) != 0)) {
result.minimumNumberShouldMatch_ = minimumNumberShouldMatch_;
}
}
@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 com.yelp.nrtsearch.server.grpc.BooleanQuery) {
return mergeFrom((com.yelp.nrtsearch.server.grpc.BooleanQuery)other);
} else {
super.mergeFrom(other);
return this;
}
}
public Builder mergeFrom(com.yelp.nrtsearch.server.grpc.BooleanQuery other) {
if (other == com.yelp.nrtsearch.server.grpc.BooleanQuery.getDefaultInstance()) return this;
if (clausesBuilder_ == null) {
if (!other.clauses_.isEmpty()) {
if (clauses_.isEmpty()) {
clauses_ = other.clauses_;
bitField0_ = (bitField0_ & ~0x00000001);
} else {
ensureClausesIsMutable();
clauses_.addAll(other.clauses_);
}
onChanged();
}
} else {
if (!other.clauses_.isEmpty()) {
if (clausesBuilder_.isEmpty()) {
clausesBuilder_.dispose();
clausesBuilder_ = null;
clauses_ = other.clauses_;
bitField0_ = (bitField0_ & ~0x00000001);
clausesBuilder_ =
com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders ?
getClausesFieldBuilder() : null;
} else {
clausesBuilder_.addAllMessages(other.clauses_);
}
}
}
if (other.getMinimumNumberShouldMatch() != 0) {
setMinimumNumberShouldMatch(other.getMinimumNumberShouldMatch());
}
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: {
com.yelp.nrtsearch.server.grpc.BooleanClause m =
input.readMessage(
com.yelp.nrtsearch.server.grpc.BooleanClause.parser(),
extensionRegistry);
if (clausesBuilder_ == null) {
ensureClausesIsMutable();
clauses_.add(m);
} else {
clausesBuilder_.addMessage(m);
}
break;
} // case 10
case 16: {
minimumNumberShouldMatch_ = input.readInt32();
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 java.util.List clauses_ =
java.util.Collections.emptyList();
private void ensureClausesIsMutable() {
if (!((bitField0_ & 0x00000001) != 0)) {
clauses_ = new java.util.ArrayList(clauses_);
bitField0_ |= 0x00000001;
}
}
private com.google.protobuf.RepeatedFieldBuilderV3<
com.yelp.nrtsearch.server.grpc.BooleanClause, com.yelp.nrtsearch.server.grpc.BooleanClause.Builder, com.yelp.nrtsearch.server.grpc.BooleanClauseOrBuilder> clausesBuilder_;
/**
*
* Clauses for a boolean query.
*
*
* repeated .luceneserver.BooleanClause clauses = 1;
*/
public java.util.List getClausesList() {
if (clausesBuilder_ == null) {
return java.util.Collections.unmodifiableList(clauses_);
} else {
return clausesBuilder_.getMessageList();
}
}
/**
*
* Clauses for a boolean query.
*
*
* repeated .luceneserver.BooleanClause clauses = 1;
*/
public int getClausesCount() {
if (clausesBuilder_ == null) {
return clauses_.size();
} else {
return clausesBuilder_.getCount();
}
}
/**
*
* Clauses for a boolean query.
*
*
* repeated .luceneserver.BooleanClause clauses = 1;
*/
public com.yelp.nrtsearch.server.grpc.BooleanClause getClauses(int index) {
if (clausesBuilder_ == null) {
return clauses_.get(index);
} else {
return clausesBuilder_.getMessage(index);
}
}
/**
*
* Clauses for a boolean query.
*
*
* repeated .luceneserver.BooleanClause clauses = 1;
*/
public Builder setClauses(
int index, com.yelp.nrtsearch.server.grpc.BooleanClause value) {
if (clausesBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
ensureClausesIsMutable();
clauses_.set(index, value);
onChanged();
} else {
clausesBuilder_.setMessage(index, value);
}
return this;
}
/**
*
* Clauses for a boolean query.
*
*
* repeated .luceneserver.BooleanClause clauses = 1;
*/
public Builder setClauses(
int index, com.yelp.nrtsearch.server.grpc.BooleanClause.Builder builderForValue) {
if (clausesBuilder_ == null) {
ensureClausesIsMutable();
clauses_.set(index, builderForValue.build());
onChanged();
} else {
clausesBuilder_.setMessage(index, builderForValue.build());
}
return this;
}
/**
*
* Clauses for a boolean query.
*
*
* repeated .luceneserver.BooleanClause clauses = 1;
*/
public Builder addClauses(com.yelp.nrtsearch.server.grpc.BooleanClause value) {
if (clausesBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
ensureClausesIsMutable();
clauses_.add(value);
onChanged();
} else {
clausesBuilder_.addMessage(value);
}
return this;
}
/**
*
* Clauses for a boolean query.
*
*
* repeated .luceneserver.BooleanClause clauses = 1;
*/
public Builder addClauses(
int index, com.yelp.nrtsearch.server.grpc.BooleanClause value) {
if (clausesBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
ensureClausesIsMutable();
clauses_.add(index, value);
onChanged();
} else {
clausesBuilder_.addMessage(index, value);
}
return this;
}
/**
*
* Clauses for a boolean query.
*
*
* repeated .luceneserver.BooleanClause clauses = 1;
*/
public Builder addClauses(
com.yelp.nrtsearch.server.grpc.BooleanClause.Builder builderForValue) {
if (clausesBuilder_ == null) {
ensureClausesIsMutable();
clauses_.add(builderForValue.build());
onChanged();
} else {
clausesBuilder_.addMessage(builderForValue.build());
}
return this;
}
/**
*
* Clauses for a boolean query.
*
*
* repeated .luceneserver.BooleanClause clauses = 1;
*/
public Builder addClauses(
int index, com.yelp.nrtsearch.server.grpc.BooleanClause.Builder builderForValue) {
if (clausesBuilder_ == null) {
ensureClausesIsMutable();
clauses_.add(index, builderForValue.build());
onChanged();
} else {
clausesBuilder_.addMessage(index, builderForValue.build());
}
return this;
}
/**
*
* Clauses for a boolean query.
*
*
* repeated .luceneserver.BooleanClause clauses = 1;
*/
public Builder addAllClauses(
java.lang.Iterable extends com.yelp.nrtsearch.server.grpc.BooleanClause> values) {
if (clausesBuilder_ == null) {
ensureClausesIsMutable();
com.google.protobuf.AbstractMessageLite.Builder.addAll(
values, clauses_);
onChanged();
} else {
clausesBuilder_.addAllMessages(values);
}
return this;
}
/**
*
* Clauses for a boolean query.
*
*
* repeated .luceneserver.BooleanClause clauses = 1;
*/
public Builder clearClauses() {
if (clausesBuilder_ == null) {
clauses_ = java.util.Collections.emptyList();
bitField0_ = (bitField0_ & ~0x00000001);
onChanged();
} else {
clausesBuilder_.clear();
}
return this;
}
/**
*
* Clauses for a boolean query.
*
*
* repeated .luceneserver.BooleanClause clauses = 1;
*/
public Builder removeClauses(int index) {
if (clausesBuilder_ == null) {
ensureClausesIsMutable();
clauses_.remove(index);
onChanged();
} else {
clausesBuilder_.remove(index);
}
return this;
}
/**
*
* Clauses for a boolean query.
*
*
* repeated .luceneserver.BooleanClause clauses = 1;
*/
public com.yelp.nrtsearch.server.grpc.BooleanClause.Builder getClausesBuilder(
int index) {
return getClausesFieldBuilder().getBuilder(index);
}
/**
*
* Clauses for a boolean query.
*
*
* repeated .luceneserver.BooleanClause clauses = 1;
*/
public com.yelp.nrtsearch.server.grpc.BooleanClauseOrBuilder getClausesOrBuilder(
int index) {
if (clausesBuilder_ == null) {
return clauses_.get(index); } else {
return clausesBuilder_.getMessageOrBuilder(index);
}
}
/**
*
* Clauses for a boolean query.
*
*
* repeated .luceneserver.BooleanClause clauses = 1;
*/
public java.util.List extends com.yelp.nrtsearch.server.grpc.BooleanClauseOrBuilder>
getClausesOrBuilderList() {
if (clausesBuilder_ != null) {
return clausesBuilder_.getMessageOrBuilderList();
} else {
return java.util.Collections.unmodifiableList(clauses_);
}
}
/**
*
* Clauses for a boolean query.
*
*
* repeated .luceneserver.BooleanClause clauses = 1;
*/
public com.yelp.nrtsearch.server.grpc.BooleanClause.Builder addClausesBuilder() {
return getClausesFieldBuilder().addBuilder(
com.yelp.nrtsearch.server.grpc.BooleanClause.getDefaultInstance());
}
/**
*
* Clauses for a boolean query.
*
*
* repeated .luceneserver.BooleanClause clauses = 1;
*/
public com.yelp.nrtsearch.server.grpc.BooleanClause.Builder addClausesBuilder(
int index) {
return getClausesFieldBuilder().addBuilder(
index, com.yelp.nrtsearch.server.grpc.BooleanClause.getDefaultInstance());
}
/**
*
* Clauses for a boolean query.
*
*
* repeated .luceneserver.BooleanClause clauses = 1;
*/
public java.util.List
getClausesBuilderList() {
return getClausesFieldBuilder().getBuilderList();
}
private com.google.protobuf.RepeatedFieldBuilderV3<
com.yelp.nrtsearch.server.grpc.BooleanClause, com.yelp.nrtsearch.server.grpc.BooleanClause.Builder, com.yelp.nrtsearch.server.grpc.BooleanClauseOrBuilder>
getClausesFieldBuilder() {
if (clausesBuilder_ == null) {
clausesBuilder_ = new com.google.protobuf.RepeatedFieldBuilderV3<
com.yelp.nrtsearch.server.grpc.BooleanClause, com.yelp.nrtsearch.server.grpc.BooleanClause.Builder, com.yelp.nrtsearch.server.grpc.BooleanClauseOrBuilder>(
clauses_,
((bitField0_ & 0x00000001) != 0),
getParentForChildren(),
isClean());
clauses_ = null;
}
return clausesBuilder_;
}
private int minimumNumberShouldMatch_ ;
/**
*
* Minimum number of optional clauses that must match.
*
*
* int32 minimumNumberShouldMatch = 2;
* @return The minimumNumberShouldMatch.
*/
@java.lang.Override
public int getMinimumNumberShouldMatch() {
return minimumNumberShouldMatch_;
}
/**
*
* Minimum number of optional clauses that must match.
*
*
* int32 minimumNumberShouldMatch = 2;
* @param value The minimumNumberShouldMatch to set.
* @return This builder for chaining.
*/
public Builder setMinimumNumberShouldMatch(int value) {
minimumNumberShouldMatch_ = value;
bitField0_ |= 0x00000002;
onChanged();
return this;
}
/**
*
* Minimum number of optional clauses that must match.
*
*
* int32 minimumNumberShouldMatch = 2;
* @return This builder for chaining.
*/
public Builder clearMinimumNumberShouldMatch() {
bitField0_ = (bitField0_ & ~0x00000002);
minimumNumberShouldMatch_ = 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:luceneserver.BooleanQuery)
}
// @@protoc_insertion_point(class_scope:luceneserver.BooleanQuery)
private static final com.yelp.nrtsearch.server.grpc.BooleanQuery DEFAULT_INSTANCE;
static {
DEFAULT_INSTANCE = new com.yelp.nrtsearch.server.grpc.BooleanQuery();
}
public static com.yelp.nrtsearch.server.grpc.BooleanQuery getDefaultInstance() {
return DEFAULT_INSTANCE;
}
private static final com.google.protobuf.Parser
PARSER = new com.google.protobuf.AbstractParser() {
@java.lang.Override
public BooleanQuery 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 com.yelp.nrtsearch.server.grpc.BooleanQuery getDefaultInstanceForType() {
return DEFAULT_INSTANCE;
}
}