io.nats.streaming.protobuf.StartPosition Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of java-nats-streaming Show documentation
Show all versions of java-nats-streaming Show documentation
Client library for working with the NATS messaging system.
// Generated by the protocol buffer compiler. DO NOT EDIT!
// source: protocol.proto
package io.nats.streaming.protobuf;
/**
*
* Enum for start position type.
*
*
* Protobuf enum {@code pb.StartPosition}
*/
public enum StartPosition
implements com.google.protobuf.ProtocolMessageEnum {
/**
* NewOnly = 0;
*/
NewOnly(0),
/**
* LastReceived = 1;
*/
LastReceived(1),
/**
* TimeDeltaStart = 2;
*/
TimeDeltaStart(2),
/**
* SequenceStart = 3;
*/
SequenceStart(3),
/**
* First = 4;
*/
First(4),
UNRECOGNIZED(-1),
;
/**
* NewOnly = 0;
*/
public static final int NewOnly_VALUE = 0;
/**
* LastReceived = 1;
*/
public static final int LastReceived_VALUE = 1;
/**
* TimeDeltaStart = 2;
*/
public static final int TimeDeltaStart_VALUE = 2;
/**
* SequenceStart = 3;
*/
public static final int SequenceStart_VALUE = 3;
/**
* First = 4;
*/
public static final int First_VALUE = 4;
public final int getNumber() {
if (this == UNRECOGNIZED) {
throw new java.lang.IllegalArgumentException(
"Can't get the number of an unknown enum value.");
}
return value;
}
/**
* @deprecated Use {@link #forNumber(int)} instead.
*/
@java.lang.Deprecated
public static StartPosition valueOf(int value) {
return forNumber(value);
}
public static StartPosition forNumber(int value) {
switch (value) {
case 0: return NewOnly;
case 1: return LastReceived;
case 2: return TimeDeltaStart;
case 3: return SequenceStart;
case 4: return First;
default: return null;
}
}
public static com.google.protobuf.Internal.EnumLiteMap
internalGetValueMap() {
return internalValueMap;
}
private static final com.google.protobuf.Internal.EnumLiteMap<
StartPosition> internalValueMap =
new com.google.protobuf.Internal.EnumLiteMap() {
public StartPosition findValueByNumber(int number) {
return StartPosition.forNumber(number);
}
};
public final com.google.protobuf.Descriptors.EnumValueDescriptor
getValueDescriptor() {
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 io.nats.streaming.protobuf.Protocol.getDescriptor().getEnumTypes().get(0);
}
private static final StartPosition[] VALUES = values();
public static StartPosition 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 StartPosition(int value) {
this.value = value;
}
// @@protoc_insertion_point(enum_scope:pb.StartPosition)
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy