// Code generated by protocol buffer compiler. Do not edit!
package emu.lunarcore.proto;

import us.hebi.quickbuf.ProtoEnum;
import us.hebi.quickbuf.ProtoUtil;

public final class LanguageTypeOuterClass {
  /**
   * Protobuf enum {@code LanguageType}
   */
  public enum LanguageType implements ProtoEnum<LanguageType> {
    /**
     * <code>LANGUAGE_NONE = 0;</code>
     */
    LANGUAGE_NONE("LANGUAGE_NONE", 0),

    /**
     * <code>LANGUAGE_SC = 1;</code>
     */
    LANGUAGE_SC("LANGUAGE_SC", 1),

    /**
     * <code>LANGUAGE_TC = 2;</code>
     */
    LANGUAGE_TC("LANGUAGE_TC", 2),

    /**
     * <code>LANGUAGE_EN = 3;</code>
     */
    LANGUAGE_EN("LANGUAGE_EN", 3),

    /**
     * <code>LANGUAGE_KR = 4;</code>
     */
    LANGUAGE_KR("LANGUAGE_KR", 4),

    /**
     * <code>LANGUAGE_JP = 5;</code>
     */
    LANGUAGE_JP("LANGUAGE_JP", 5),

    /**
     * <code>LANGUAGE_FR = 6;</code>
     */
    LANGUAGE_FR("LANGUAGE_FR", 6),

    /**
     * <code>LANGUAGE_DE = 7;</code>
     */
    LANGUAGE_DE("LANGUAGE_DE", 7),

    /**
     * <code>LANGUAGE_ES = 8;</code>
     */
    LANGUAGE_ES("LANGUAGE_ES", 8),

    /**
     * <code>LANGUAGE_PT = 9;</code>
     */
    LANGUAGE_PT("LANGUAGE_PT", 9),

    /**
     * <code>LANGUAGE_RU = 10;</code>
     */
    LANGUAGE_RU("LANGUAGE_RU", 10),

    /**
     * <code>LANGUAGE_TH = 11;</code>
     */
    LANGUAGE_TH("LANGUAGE_TH", 11),

    /**
     * <code>LANGUAGE_VI = 12;</code>
     */
    LANGUAGE_VI("LANGUAGE_VI", 12),

    /**
     * <code>LANGUAGE_ID = 13;</code>
     */
    LANGUAGE_ID("LANGUAGE_ID", 13);

    /**
     * <code>LANGUAGE_NONE = 0;</code>
     */
    public static final int LANGUAGE_NONE_VALUE = 0;

    /**
     * <code>LANGUAGE_SC = 1;</code>
     */
    public static final int LANGUAGE_SC_VALUE = 1;

    /**
     * <code>LANGUAGE_TC = 2;</code>
     */
    public static final int LANGUAGE_TC_VALUE = 2;

    /**
     * <code>LANGUAGE_EN = 3;</code>
     */
    public static final int LANGUAGE_EN_VALUE = 3;

    /**
     * <code>LANGUAGE_KR = 4;</code>
     */
    public static final int LANGUAGE_KR_VALUE = 4;

    /**
     * <code>LANGUAGE_JP = 5;</code>
     */
    public static final int LANGUAGE_JP_VALUE = 5;

    /**
     * <code>LANGUAGE_FR = 6;</code>
     */
    public static final int LANGUAGE_FR_VALUE = 6;

    /**
     * <code>LANGUAGE_DE = 7;</code>
     */
    public static final int LANGUAGE_DE_VALUE = 7;

    /**
     * <code>LANGUAGE_ES = 8;</code>
     */
    public static final int LANGUAGE_ES_VALUE = 8;

    /**
     * <code>LANGUAGE_PT = 9;</code>
     */
    public static final int LANGUAGE_PT_VALUE = 9;

    /**
     * <code>LANGUAGE_RU = 10;</code>
     */
    public static final int LANGUAGE_RU_VALUE = 10;

    /**
     * <code>LANGUAGE_TH = 11;</code>
     */
    public static final int LANGUAGE_TH_VALUE = 11;

    /**
     * <code>LANGUAGE_VI = 12;</code>
     */
    public static final int LANGUAGE_VI_VALUE = 12;

    /**
     * <code>LANGUAGE_ID = 13;</code>
     */
    public static final int LANGUAGE_ID_VALUE = 13;

    private final String name;

    private final int number;

    private LanguageType(String name, int number) {
      this.name = name;
      this.number = number;
    }

    /**
     * @return the string representation of enum entry
     */
    @Override
    public String getName() {
      return name;
    }

    /**
     * @return the numeric wire value of this enum entry
     */
    @Override
    public int getNumber() {
      return number;
    }

    /**
     * @return a converter that maps between this enum's numeric and text representations
     */
    public static ProtoEnum.EnumConverter<LanguageType> converter() {
      return LanguageTypeConverter.INSTANCE;
    }

    /**
     * @param value The numeric wire value of the corresponding enum entry.
     * @return The enum associated with the given numeric wire value, or null if unknown.
     */
    public static LanguageType forNumber(int value) {
      return LanguageTypeConverter.INSTANCE.forNumber(value);
    }

    /**
     * @param value The numeric wire value of the corresponding enum entry.
     * @param other Fallback value in case the value is not known.
     * @return The enum associated with the given numeric wire value, or the fallback value if unknown.
     */
    public static LanguageType forNumberOr(int number, LanguageType other) {
      LanguageType value = forNumber(number);
      return value == null ? other : value;
    }

    enum LanguageTypeConverter implements ProtoEnum.EnumConverter<LanguageType> {
      INSTANCE;

      private static final LanguageType[] lookup = new LanguageType[14];

      static {
        lookup[0] = LANGUAGE_NONE;
        lookup[1] = LANGUAGE_SC;
        lookup[2] = LANGUAGE_TC;
        lookup[3] = LANGUAGE_EN;
        lookup[4] = LANGUAGE_KR;
        lookup[5] = LANGUAGE_JP;
        lookup[6] = LANGUAGE_FR;
        lookup[7] = LANGUAGE_DE;
        lookup[8] = LANGUAGE_ES;
        lookup[9] = LANGUAGE_PT;
        lookup[10] = LANGUAGE_RU;
        lookup[11] = LANGUAGE_TH;
        lookup[12] = LANGUAGE_VI;
        lookup[13] = LANGUAGE_ID;
      }

      @Override
      public final LanguageType forNumber(final int value) {
        if (value >= 0 && value < lookup.length) {
          return lookup[value];
        }
        return null;
      }

      @Override
      public final LanguageType forName(final CharSequence value) {
        if (value.length() == 11) {
          if (ProtoUtil.isEqual("LANGUAGE_SC", value)) {
            return LANGUAGE_SC;
          }
          if (ProtoUtil.isEqual("LANGUAGE_TC", value)) {
            return LANGUAGE_TC;
          }
          if (ProtoUtil.isEqual("LANGUAGE_EN", value)) {
            return LANGUAGE_EN;
          }
          if (ProtoUtil.isEqual("LANGUAGE_KR", value)) {
            return LANGUAGE_KR;
          }
          if (ProtoUtil.isEqual("LANGUAGE_JP", value)) {
            return LANGUAGE_JP;
          }
          if (ProtoUtil.isEqual("LANGUAGE_FR", value)) {
            return LANGUAGE_FR;
          }
          if (ProtoUtil.isEqual("LANGUAGE_DE", value)) {
            return LANGUAGE_DE;
          }
          if (ProtoUtil.isEqual("LANGUAGE_ES", value)) {
            return LANGUAGE_ES;
          }
          if (ProtoUtil.isEqual("LANGUAGE_PT", value)) {
            return LANGUAGE_PT;
          }
          if (ProtoUtil.isEqual("LANGUAGE_RU", value)) {
            return LANGUAGE_RU;
          }
          if (ProtoUtil.isEqual("LANGUAGE_TH", value)) {
            return LANGUAGE_TH;
          }
          if (ProtoUtil.isEqual("LANGUAGE_VI", value)) {
            return LANGUAGE_VI;
          }
          if (ProtoUtil.isEqual("LANGUAGE_ID", value)) {
            return LANGUAGE_ID;
          }
        }
        if (value.length() == 13) {
          if (ProtoUtil.isEqual("LANGUAGE_NONE", value)) {
            return LANGUAGE_NONE;
          }
        }
        return null;
      }
    }
  }
}
