All Downloads are FREE. Search and download functionalities are using the official Maven repository.

org.yamcs.protobuf.AlarmSeverity Maven / Gradle / Ivy

There is a newer version: 5.10.9
Show newest version
// Generated by the protocol buffer compiler.  DO NOT EDIT!
// source: yamcs/protobuf/alarms/alarms.proto

package org.yamcs.protobuf;

/**
 * Protobuf enum {@code yamcs.protobuf.alarms.AlarmSeverity}
 */
public enum AlarmSeverity
    implements com.google.protobuf.ProtocolMessageEnum {
  /**
   * WATCH = 1;
   */
  WATCH(1),
  /**
   * WARNING = 2;
   */
  WARNING(2),
  /**
   * DISTRESS = 3;
   */
  DISTRESS(3),
  /**
   * CRITICAL = 4;
   */
  CRITICAL(4),
  /**
   * SEVERE = 5;
   */
  SEVERE(5),
  ;

  /**
   * WATCH = 1;
   */
  public static final int WATCH_VALUE = 1;
  /**
   * WARNING = 2;
   */
  public static final int WARNING_VALUE = 2;
  /**
   * DISTRESS = 3;
   */
  public static final int DISTRESS_VALUE = 3;
  /**
   * CRITICAL = 4;
   */
  public static final int CRITICAL_VALUE = 4;
  /**
   * SEVERE = 5;
   */
  public static final int SEVERE_VALUE = 5;


  public final int getNumber() {
    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 AlarmSeverity 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 AlarmSeverity forNumber(int value) {
    switch (value) {
      case 1: return WATCH;
      case 2: return WARNING;
      case 3: return DISTRESS;
      case 4: return CRITICAL;
      case 5: return SEVERE;
      default: return null;
    }
  }

  public static com.google.protobuf.Internal.EnumLiteMap
      internalGetValueMap() {
    return internalValueMap;
  }
  private static final com.google.protobuf.Internal.EnumLiteMap<
      AlarmSeverity> internalValueMap =
        new com.google.protobuf.Internal.EnumLiteMap() {
          public AlarmSeverity findValueByNumber(int number) {
            return AlarmSeverity.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.yamcs.protobuf.AlarmsProto.getDescriptor().getEnumTypes().get(2);
  }

  private static final AlarmSeverity[] VALUES = values();

  public static AlarmSeverity valueOf(
      com.google.protobuf.Descriptors.EnumValueDescriptor desc) {
    if (desc.getType() != getDescriptor()) {
      throw new java.lang.IllegalArgumentException(
        "EnumValueDescriptor is not for this type.");
    }
    return VALUES[desc.getIndex()];
  }

  private final int value;

  private AlarmSeverity(int value) {
    this.value = value;
  }

  // @@protoc_insertion_point(enum_scope:yamcs.protobuf.alarms.AlarmSeverity)
}





© 2015 - 2025 Weber Informatics LLC | Privacy Policy