Class OidcServerException

    • Constructor Detail

      • OidcServerException

        public OidcServerException​(java.lang.String description,
                                   java.lang.String code,
                                   int httpStatus,
                                   java.lang.Throwable cause)
        Constructs an instance of this exception with the referenced arguments.
        Parameters:
        desription - The error description for this exception. Can be null if the code is null
        code - The error code for this exception. Specify null if the code is unknown.
        cause - exception causing the problem
        httpStatus - The HTTP status code to associate to this exception.
      • OidcServerException

        public OidcServerException​(java.lang.String description,
                                   java.lang.String code,
                                   int httpStatus)
      • OidcServerException

        public OidcServerException​(com.ibm.ws.security.oauth20.error.impl.BrowserAndServerLogMessage browserServerLogMsg,
                                   java.lang.String code,
                                   int httpStatus)
      • OidcServerException

        public OidcServerException​(com.ibm.ws.security.oauth20.error.impl.BrowserAndServerLogMessage browserServerLogMsg,
                                   java.lang.String code,
                                   int httpStatus,
                                   java.lang.Throwable cause)
    • Method Detail

      • getErrorDescription

        public java.lang.String getErrorDescription()
        Returns the error description for this exception, as an English string.
        Returns:
        The OAuth error description.
      • getErrorDescription

        public java.lang.String getErrorDescription​(java.util.Enumeration<java.util.Locale> locales)
      • getErrorCode

        public java.lang.String getErrorCode()
        Returns the error code associated to this exception.
        Returns:
        The error code for this exception.
      • getHttpStatus

        public int getHttpStatus()
        Returns the HTTP status code associated to this exception.
        Returns:
        The HTTP status code. Will be -1 if no code was specified.
      • isComplete

        public boolean isComplete()
      • toJSON

        public java.lang.String toJSON()
        Constructs an OAuth 2.0 error response from the exception state, per RFC6749 section 5.2.
        Returns:
        An error JSON string - never null.