public class HttpResponseException extends ClientProtocolException
| Constructor and Description | 
|---|
| HttpResponseException(int statusCode,
                     String reasonPhrase)Constructs a new instance of  HttpResponseExceptionwith the given
 status code and reason phrase, and no content bytes or content type. | 
| HttpResponseException(int statusCode,
                     String reasonPhrase,
                     byte[] contentBytes,
                     ContentType contentType)Constructs a new instance of  HttpResponseExceptionwith the given
 status code, reason phrase, content bytes, and content type. | 
| Modifier and Type | Method and Description | 
|---|---|
| byte[] | getContentBytes() | 
| ContentType | getContentType() | 
| String | getReasonPhrase() | 
| int | getStatusCode() | 
addSuppressed, fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, getSuppressed, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toStringpublic HttpResponseException(int statusCode,
                             String reasonPhrase)
HttpResponseException with the given
 status code and reason phrase, and no content bytes or content type.statusCode - the HTTP status codereasonPhrase - the reason phrase associated with the HTTP status codepublic HttpResponseException(int statusCode,
                             String reasonPhrase,
                             byte[] contentBytes,
                             ContentType contentType)
HttpResponseException with the given
 status code, reason phrase, content bytes, and content type.statusCode - the HTTP status codereasonPhrase - the reason phrase associated with the HTTP status codecontentBytes - the content bytes of the HTTP responsecontentType - the content type of the HTTP responsepublic int getStatusCode()
public String getReasonPhrase()
public byte[] getContentBytes()
public ContentType getContentType()
Copyright © 1999–2021 The Apache Software Foundation. All rights reserved.