// 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 RogueBuffSourceOuterClass {
  /**
   * Protobuf enum {@code RogueBuffSource}
   */
  public enum RogueBuffSource implements ProtoEnum<RogueBuffSource> {
    /**
     * <code>ROGUE_BUFF_SOURCE_TYPE_NONE = 0;</code>
     */
    ROGUE_BUFF_SOURCE_TYPE_NONE("ROGUE_BUFF_SOURCE_TYPE_NONE", 0),

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

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

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

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

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

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

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

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

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

    /**
     * <code>ROGUE_BUFF_SOURCE_TYPE_NONE = 0;</code>
     */
    public static final int ROGUE_BUFF_SOURCE_TYPE_NONE_VALUE = 0;

    /**
     * <code>ROGUE_BUFF_SOURCE_TYPE_SELECT = 1;</code>
     */
    public static final int ROGUE_BUFF_SOURCE_TYPE_SELECT_VALUE = 1;

    /**
     * <code>ROGUE_BUFF_SOURCE_TYPE_ENHANCE = 2;</code>
     */
    public static final int ROGUE_BUFF_SOURCE_TYPE_ENHANCE_VALUE = 2;

    /**
     * <code>ROGUE_BUFF_SOURCE_TYPE_MIRACLE = 3;</code>
     */
    public static final int ROGUE_BUFF_SOURCE_TYPE_MIRACLE_VALUE = 3;

    /**
     * <code>ROGUE_BUFF_SOURCE_TYPE_DIALOGUE = 4;</code>
     */
    public static final int ROGUE_BUFF_SOURCE_TYPE_DIALOGUE_VALUE = 4;

    /**
     * <code>ROGUE_BUFF_SOURCE_TYPE_BONUS = 5;</code>
     */
    public static final int ROGUE_BUFF_SOURCE_TYPE_BONUS_VALUE = 5;

    /**
     * <code>ROGUE_BUFF_SOURCE_TYPE_MAZE_SKILL = 6;</code>
     */
    public static final int ROGUE_BUFF_SOURCE_TYPE_MAZE_SKILL_VALUE = 6;

    /**
     * <code>ROGUE_BUFF_SOURCE_TYPE_SHOP = 7;</code>
     */
    public static final int ROGUE_BUFF_SOURCE_TYPE_SHOP_VALUE = 7;

    /**
     * <code>ROGUE_BUFF_SOURCE_TYPE_LEVEL_MECHANISM = 8;</code>
     */
    public static final int ROGUE_BUFF_SOURCE_TYPE_LEVEL_MECHANISM_VALUE = 8;

    /**
     * <code>ROGUE_BUFF_SOURCE_TYPE_ENDLESS_LEVEL_START = 9;</code>
     */
    public static final int ROGUE_BUFF_SOURCE_TYPE_ENDLESS_LEVEL_START_VALUE = 9;

    private final String name;

    private final int number;

    private RogueBuffSource(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<RogueBuffSource> converter() {
      return RogueBuffSourceConverter.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 RogueBuffSource forNumber(int value) {
      return RogueBuffSourceConverter.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 RogueBuffSource forNumberOr(int number, RogueBuffSource other) {
      RogueBuffSource value = forNumber(number);
      return value == null ? other : value;
    }

    enum RogueBuffSourceConverter implements ProtoEnum.EnumConverter<RogueBuffSource> {
      INSTANCE;

      private static final RogueBuffSource[] lookup = new RogueBuffSource[10];

      static {
        lookup[0] = ROGUE_BUFF_SOURCE_TYPE_NONE;
        lookup[1] = ROGUE_BUFF_SOURCE_TYPE_SELECT;
        lookup[2] = ROGUE_BUFF_SOURCE_TYPE_ENHANCE;
        lookup[3] = ROGUE_BUFF_SOURCE_TYPE_MIRACLE;
        lookup[4] = ROGUE_BUFF_SOURCE_TYPE_DIALOGUE;
        lookup[5] = ROGUE_BUFF_SOURCE_TYPE_BONUS;
        lookup[6] = ROGUE_BUFF_SOURCE_TYPE_MAZE_SKILL;
        lookup[7] = ROGUE_BUFF_SOURCE_TYPE_SHOP;
        lookup[8] = ROGUE_BUFF_SOURCE_TYPE_LEVEL_MECHANISM;
        lookup[9] = ROGUE_BUFF_SOURCE_TYPE_ENDLESS_LEVEL_START;
      }

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

      @Override
      public final RogueBuffSource forName(final CharSequence value) {
        switch (value.length()) {
          case 27: {
            if (ProtoUtil.isEqual("ROGUE_BUFF_SOURCE_TYPE_NONE", value)) {
              return ROGUE_BUFF_SOURCE_TYPE_NONE;
            }
            if (ProtoUtil.isEqual("ROGUE_BUFF_SOURCE_TYPE_SHOP", value)) {
              return ROGUE_BUFF_SOURCE_TYPE_SHOP;
            }
            break;
          }
          case 28: {
            if (ProtoUtil.isEqual("ROGUE_BUFF_SOURCE_TYPE_BONUS", value)) {
              return ROGUE_BUFF_SOURCE_TYPE_BONUS;
            }
            break;
          }
          case 29: {
            if (ProtoUtil.isEqual("ROGUE_BUFF_SOURCE_TYPE_SELECT", value)) {
              return ROGUE_BUFF_SOURCE_TYPE_SELECT;
            }
            break;
          }
          case 30: {
            if (ProtoUtil.isEqual("ROGUE_BUFF_SOURCE_TYPE_ENHANCE", value)) {
              return ROGUE_BUFF_SOURCE_TYPE_ENHANCE;
            }
            if (ProtoUtil.isEqual("ROGUE_BUFF_SOURCE_TYPE_MIRACLE", value)) {
              return ROGUE_BUFF_SOURCE_TYPE_MIRACLE;
            }
            break;
          }
          case 31: {
            if (ProtoUtil.isEqual("ROGUE_BUFF_SOURCE_TYPE_DIALOGUE", value)) {
              return ROGUE_BUFF_SOURCE_TYPE_DIALOGUE;
            }
            break;
          }
          case 33: {
            if (ProtoUtil.isEqual("ROGUE_BUFF_SOURCE_TYPE_MAZE_SKILL", value)) {
              return ROGUE_BUFF_SOURCE_TYPE_MAZE_SKILL;
            }
            break;
          }
          case 38: {
            if (ProtoUtil.isEqual("ROGUE_BUFF_SOURCE_TYPE_LEVEL_MECHANISM", value)) {
              return ROGUE_BUFF_SOURCE_TYPE_LEVEL_MECHANISM;
            }
            break;
          }
          case 42: {
            if (ProtoUtil.isEqual("ROGUE_BUFF_SOURCE_TYPE_ENDLESS_LEVEL_START", value)) {
              return ROGUE_BUFF_SOURCE_TYPE_ENDLESS_LEVEL_START;
            }
            break;
          }
        }
        return null;
      }
    }
  }
}
