
org.tensorflow.util.WorkerHealth Maven / Gradle / Ivy
The newest version!
// Generated by the protocol buffer compiler. DO NOT EDIT!
// source: tensorflow/core/util/event.proto
package org.tensorflow.util;
/**
*
* Current health status of a worker.
*
*
* Protobuf enum {@code tensorflow.WorkerHealth}
*/
public enum WorkerHealth
implements com.google.protobuf.ProtocolMessageEnum {
/**
*
* By default a worker is healthy.
*
*
* OK = 0;
*/
OK(0),
/**
* RECEIVED_SHUTDOWN_SIGNAL = 1;
*/
RECEIVED_SHUTDOWN_SIGNAL(1),
/**
* INTERNAL_ERROR = 2;
*/
INTERNAL_ERROR(2),
UNRECOGNIZED(-1),
;
/**
*
* By default a worker is healthy.
*
*
* OK = 0;
*/
public static final int OK_VALUE = 0;
/**
* RECEIVED_SHUTDOWN_SIGNAL = 1;
*/
public static final int RECEIVED_SHUTDOWN_SIGNAL_VALUE = 1;
/**
* INTERNAL_ERROR = 2;
*/
public static final int INTERNAL_ERROR_VALUE = 2;
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 WorkerHealth valueOf(int value) {
return forNumber(value);
}
public static WorkerHealth forNumber(int value) {
switch (value) {
case 0: return OK;
case 1: return RECEIVED_SHUTDOWN_SIGNAL;
case 2: return INTERNAL_ERROR;
default: return null;
}
}
public static com.google.protobuf.Internal.EnumLiteMap
internalGetValueMap() {
return internalValueMap;
}
private static final com.google.protobuf.Internal.EnumLiteMap<
WorkerHealth> internalValueMap =
new com.google.protobuf.Internal.EnumLiteMap() {
public WorkerHealth findValueByNumber(int number) {
return WorkerHealth.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 org.tensorflow.util.EventProtos.getDescriptor().getEnumTypes().get(0);
}
private static final WorkerHealth[] VALUES = values();
public static WorkerHealth 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 WorkerHealth(int value) {
this.value = value;
}
// @@protoc_insertion_point(enum_scope:tensorflow.WorkerHealth)
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy