com.yelp.nrtsearch.server.grpc.Selector 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;
/**
*
* For multi valued fields, how to select which value is used for sorting
*
*
* Protobuf enum {@code luceneserver.Selector}
*/
public enum Selector
implements com.google.protobuf.ProtocolMessageEnum {
/**
*
* Minimum value
*
*
* MIN = 0;
*/
MIN(0),
/**
*
* Maximum value
*
*
* MAX = 1;
*/
MAX(1),
/**
*
* Middle value of the set; if there are an even number of values, the lower of the middle two is chosen
*
*
* MIDDLE_MIN = 2;
*/
MIDDLE_MIN(2),
/**
*
* Middle value of the set; if there are an even number of values, the upper of the middle two is chosen
*
*
* MIDDLE_MAX = 3;
*/
MIDDLE_MAX(3),
UNRECOGNIZED(-1),
;
/**
*
* Minimum value
*
*
* MIN = 0;
*/
public static final int MIN_VALUE = 0;
/**
*
* Maximum value
*
*
* MAX = 1;
*/
public static final int MAX_VALUE = 1;
/**
*
* Middle value of the set; if there are an even number of values, the lower of the middle two is chosen
*
*
* MIDDLE_MIN = 2;
*/
public static final int MIDDLE_MIN_VALUE = 2;
/**
*
* Middle value of the set; if there are an even number of values, the upper of the middle two is chosen
*
*
* MIDDLE_MAX = 3;
*/
public static final int MIDDLE_MAX_VALUE = 3;
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 Selector 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 Selector forNumber(int value) {
switch (value) {
case 0: return MIN;
case 1: return MAX;
case 2: return MIDDLE_MIN;
case 3: return MIDDLE_MAX;
default: return null;
}
}
public static com.google.protobuf.Internal.EnumLiteMap
internalGetValueMap() {
return internalValueMap;
}
private static final com.google.protobuf.Internal.EnumLiteMap<
Selector> internalValueMap =
new com.google.protobuf.Internal.EnumLiteMap() {
public Selector findValueByNumber(int number) {
return Selector.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 com.yelp.nrtsearch.server.grpc.SearchResponseProto.getDescriptor().getEnumTypes().get(5);
}
private static final Selector[] VALUES = values();
public static Selector 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 Selector(int value) {
this.value = value;
}
// @@protoc_insertion_point(enum_scope:luceneserver.Selector)
}