main.java.com.streamlayer.common.FailoverStrategy Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of sl-protofiles Show documentation
Show all versions of sl-protofiles Show documentation
StreamLayer Java Protofiles
// Generated by the protocol buffer compiler. DO NOT EDIT!
// source: streamlayer/common/streamlayer_common.proto
// Protobuf Java Version: 3.25.3
package com.streamlayer.common;
/**
* Protobuf enum {@code streamlayer.common.FailoverStrategy}
*/
public enum FailoverStrategy
implements com.google.protobuf.Internal.EnumLite {
/**
* FAILOVER_STRATEGY_INVALID = 0;
*/
FAILOVER_STRATEGY_INVALID(0),
/**
* FAILOVER_STRATEGY_UNSET = 1;
*/
FAILOVER_STRATEGY_UNSET(1),
/**
*
* ignore errors
*
*
* FAILOVER_STRATEGY_IGNORE = 2;
*/
FAILOVER_STRATEGY_IGNORE(2),
/**
*
* close a stream on an error
*
*
* FAILOVER_STRATEGY_EARLY = 3;
*/
FAILOVER_STRATEGY_EARLY(3),
/**
*
* notify about an error, but keep stream open and handle other calls
*
*
* FAILOVER_STRATEGY_GRACE = 4;
*/
FAILOVER_STRATEGY_GRACE(4),
UNRECOGNIZED(-1),
;
/**
* FAILOVER_STRATEGY_INVALID = 0;
*/
public static final int FAILOVER_STRATEGY_INVALID_VALUE = 0;
/**
* FAILOVER_STRATEGY_UNSET = 1;
*/
public static final int FAILOVER_STRATEGY_UNSET_VALUE = 1;
/**
*
* ignore errors
*
*
* FAILOVER_STRATEGY_IGNORE = 2;
*/
public static final int FAILOVER_STRATEGY_IGNORE_VALUE = 2;
/**
*
* close a stream on an error
*
*
* FAILOVER_STRATEGY_EARLY = 3;
*/
public static final int FAILOVER_STRATEGY_EARLY_VALUE = 3;
/**
*
* notify about an error, but keep stream open and handle other calls
*
*
* FAILOVER_STRATEGY_GRACE = 4;
*/
public static final int FAILOVER_STRATEGY_GRACE_VALUE = 4;
@java.lang.Override
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 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 FailoverStrategy valueOf(int value) {
return forNumber(value);
}
public static FailoverStrategy forNumber(int value) {
switch (value) {
case 0: return FAILOVER_STRATEGY_INVALID;
case 1: return FAILOVER_STRATEGY_UNSET;
case 2: return FAILOVER_STRATEGY_IGNORE;
case 3: return FAILOVER_STRATEGY_EARLY;
case 4: return FAILOVER_STRATEGY_GRACE;
default: return null;
}
}
public static com.google.protobuf.Internal.EnumLiteMap
internalGetValueMap() {
return internalValueMap;
}
private static final com.google.protobuf.Internal.EnumLiteMap<
FailoverStrategy> internalValueMap =
new com.google.protobuf.Internal.EnumLiteMap() {
@java.lang.Override
public FailoverStrategy findValueByNumber(int number) {
return FailoverStrategy.forNumber(number);
}
};
public static com.google.protobuf.Internal.EnumVerifier
internalGetVerifier() {
return FailoverStrategyVerifier.INSTANCE;
}
private static final class FailoverStrategyVerifier implements
com.google.protobuf.Internal.EnumVerifier {
static final com.google.protobuf.Internal.EnumVerifier INSTANCE = new FailoverStrategyVerifier();
@java.lang.Override
public boolean isInRange(int number) {
return FailoverStrategy.forNumber(number) != null;
}
};
private final int value;
private FailoverStrategy(int value) {
this.value = value;
}
// @@protoc_insertion_point(enum_scope:streamlayer.common.FailoverStrategy)
}