Enum ResponseErrorType

    • Enum Constant Detail

      • UNKNOWN

        public static final ResponseErrorType UNKNOWN
        Represents an unknown error.
      • SHOP_NOT_FOUND

        public static final ResponseErrorType SHOP_NOT_FOUND
        Represents the shop not found error.
      • ELEMENT_NOT_FOUND

        public static final ResponseErrorType ELEMENT_NOT_FOUND
        Represents the requested element not found error.
      • MISSING_REQUIRED_PARAMETERS

        public static final ResponseErrorType MISSING_REQUIRED_PARAMETERS
        Represents the missing required request parameter(s) error.
      • WRONG_PARAMETER_VALUE_FORMAT

        public static final ResponseErrorType WRONG_PARAMETER_VALUE_FORMAT
        Represents the request parameters format mismatch error.
      • PLUGIN_IS_DISABLED

        public static final ResponseErrorType PLUGIN_IS_DISABLED
        Represents the plugin is disabled error.
      • PLUGIN_INTERNAL_ERROR

        public static final ResponseErrorType PLUGIN_INTERNAL_ERROR
        Represents the internal plugin error.
    • Method Detail

      • values

        public static ResponseErrorType[] values()
        Returns an array containing the constants of this enum type, in the order they are declared. This method may be used to iterate over the constants as follows:
        for (ResponseErrorType c : ResponseErrorType.values())
            System.out.println(c);
        
        Returns:
        an array containing the constants of this enum type, in the order they are declared
      • valueOf

        public static ResponseErrorType valueOf​(String name)
        Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (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 type has no constant with the specified name
        NullPointerException - if the argument is null
      • getByNumber

        @NotNull
        public static @NotNull ResponseErrorType getByNumber​(int errorCode)
        Get the enum constant by the known error code.
        If a relevant enum constant with this error code will not be found then this method will return UNKNOWN constant as default.
        Parameters:
        errorCode - the error code to find an enum constant.
        Returns:
        The found response error enum constant or UNKNOWN by default.