Enum Class OpenErrorCode

java.lang.Object
java.lang.Enum<OpenErrorCode>
io.github.xezzon.zeroweb.common.exception.OpenErrorCode
All Implemented Interfaces:
IErrorCode, Serializable, Comparable<OpenErrorCode>, Constable

public enum OpenErrorCode extends Enum<OpenErrorCode> implements IErrorCode
错误码分配中心
Author:
xezzon
  • Enum Constant Details

    • PUBLISHED_OPENAPI_CANNOT_BE_MODIFY

      public static final OpenErrorCode PUBLISHED_OPENAPI_CANNOT_BE_MODIFY
    • UNPUBLISHED_OPENAPI_CANNOT_BE_SUBSCRIBE

      public static final OpenErrorCode UNPUBLISHED_OPENAPI_CANNOT_BE_SUBSCRIBE
    • INVALID_ACCESS_KEY

      public static final OpenErrorCode INVALID_ACCESS_KEY
    • UNSUBSCRIBED_OPENAPI

      public static final OpenErrorCode UNSUBSCRIBED_OPENAPI
  • Method Details

    • values

      public static OpenErrorCode[] values()
      Returns an array containing the constants of this enum class, in the order they are declared.
      Returns:
      an array containing the constants of this enum class, in the order they are declared
    • valueOf

      public static OpenErrorCode valueOf(String name)
      Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (Extraneous whitespace characters are not permitted.)
      Parameters:
      name - the name of the enum constant to be returned.
      Returns:
      the enum constant with the specified name
      Throws:
      IllegalArgumentException - if this enum class has no constant with the specified name
      NullPointerException - if the argument is null
    • mapping

      public static IErrorCode mapping(Class<? extends Throwable> exceptionClass)
    • sourceType

      public ErrorSourceType sourceType()
      Specified by:
      sourceType in interface IErrorCode
      Returns:
      错误来源类型
    • moduleCode

      public byte moduleCode()
      Description copied from interface: IErrorCode
      模块编码 0 为公共模块 ZeroWeb 的模块编码从 -1~-128 分配 1~127 由使用者分配
      Specified by:
      moduleCode in interface IErrorCode
      Returns:
      模块编码