Enum HTTPStatus

    • Enum Constant Detail

      • CREATED_X

        public static final HTTPStatus CREATED_X
        Error: 201 (created).
      • BAD_REQUEST_X

        public static final HTTPStatus BAD_REQUEST_X
        Error: 400 (bad request).
      • UNKNOWN_PARAM_X

        public static final HTTPStatus UNKNOWN_PARAM_X
        Error 400, "Unknown parameter".
      • MULTIPLE_OPS_X

        public static final HTTPStatus MULTIPLE_OPS_X
        Error 400, "Multiple operations supplied".
      • MULTIPLE_CONTEXTS

        public static final HTTPStatus MULTIPLE_CONTEXTS
        Error 400, "Multiple contexts supplied.".
      • NOT_FOUND_X

        public static final HTTPStatus NOT_FOUND_X
        Error: 404 (not found).
      • NO_DATABASE_SPECIFIED

        public static final HTTPStatus NO_DATABASE_SPECIFIED
        Error: 404, "No path specified".
      • SERVICE_NOT_FOUND

        public static final HTTPStatus SERVICE_NOT_FOUND
        Error: 404, "Service not found".
      • NO_RESTXQ_DIRECTORY

        public static final HTTPStatus NO_RESTXQ_DIRECTORY
        Error: 500, "RESTXQ path cannot be resolved.".
      • METHOD_NOT_SUPPORTED_X

        public static final HTTPStatus METHOD_NOT_SUPPORTED_X
        Error 501, "Method not supported.".
    • Method Detail

      • values

        public static HTTPStatus[] 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 (HTTPStatus c : HTTPStatus.values())
            System.out.println(c);
        
        Returns:
        an array containing the constants of this enum type, in the order they are declared
      • valueOf

        public static HTTPStatus 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
      • get

        public HTTPException get​(Object... ext)
        Returns an HTTP exception.
        Parameters:
        ext - extended info
        Returns:
        HTTP exception