Package org.htmlunit

Class FailingHttpStatusCodeException

  • All Implemented Interfaces:
    java.io.Serializable

    public class FailingHttpStatusCodeException
    extends java.lang.RuntimeException
    An exception that is thrown when the server returns a failing status code.
    See Also:
    Serialized Form
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      WebResponse getResponse()
      Gets the failing response.
      int getStatusCode()
      Returns the failing status code.
      java.lang.String getStatusMessage()
      Returns the message associated with the failing 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

      • FailingHttpStatusCodeException

        public FailingHttpStatusCodeException​(WebResponse failingResponse)
        Creates an instance.
        Parameters:
        failingResponse - the failing response
      • FailingHttpStatusCodeException

        public FailingHttpStatusCodeException​(java.lang.String message,
                                              WebResponse failingResponse)
        Creates an instance.
        Parameters:
        message - the message
        failingResponse - the failing response
    • Method Detail

      • getStatusCode

        public int getStatusCode()
        Returns the failing status code.
        Returns:
        the code
      • getStatusMessage

        public java.lang.String getStatusMessage()
        Returns the message associated with the failing status code.
        Returns:
        the message
      • getResponse

        public WebResponse getResponse()
        Gets the failing response.
        Returns:
        the response