Class HttpException

  • All Implemented Interfaces:
    java.io.Serializable

    public class HttpException
    extends java.lang.Exception
    Exception which represents a HTTP fault
    See Also:
    Serialized Form
    • Constructor Summary

      Constructors 
      Constructor Description
      HttpException​(java.lang.Integer httpStatus)
      Create new instance with HTTP status
      HttpException​(java.lang.Integer httpStatus, java.lang.String message)
      Create new instance with HTTP status and without message
      HttpException​(java.lang.String message)
      Create new instance with message
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      int getHttpStatus()
      Return HTTP status code
      • Methods inherited from class java.lang.Throwable

        addSuppressed, fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, getSuppressed, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
    • Constructor Detail

      • HttpException

        public HttpException​(java.lang.String message)
        Create new instance with message
        Parameters:
        message - received exception message
      • HttpException

        public HttpException​(java.lang.Integer httpStatus)
        Create new instance with HTTP status
        Parameters:
        httpStatus - received HTTP status code
      • HttpException

        public HttpException​(java.lang.Integer httpStatus,
                             java.lang.String message)
        Create new instance with HTTP status and without message
        Parameters:
        httpStatus - received HTTP status code
        message - received exception message
    • Method Detail

      • getHttpStatus

        public int getHttpStatus()
        Return HTTP status code
        Returns:
        HTTP status code