public class RedirectException extends IOException
IOException
used to convey that a connection has failed as a redirect has been encountered.Constructor and Description |
---|
RedirectException(int statusCode,
String location)
Constructs a new
RedirectException instance. |
RedirectException(String msg,
int statusCode,
String location)
Constructs a new
RedirectException instance with an initial message. |
RedirectException(String msg,
Throwable cause,
int statusCode,
String location)
Constructs a new
RedirectException instance with an initial message and cause. |
RedirectException(Throwable cause,
int statusCode,
String location)
Constructs a new
RedirectException instance with an initial cause. |
Modifier and Type | Method and Description |
---|---|
String |
getLocation()
Get the redirection target location.
|
int |
getStatusCode()
Get the HTTP status code.
|
addSuppressed, fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, getSuppressed, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString
public RedirectException(int statusCode, String location)
RedirectException
instance. The message is left blank (null
), and no cause is
specified.statusCode
- the status codelocation
- the redirection location, if anypublic RedirectException(String msg, int statusCode, String location)
RedirectException
instance with an initial message. No cause is specified.msg
- the messagestatusCode
- the status codelocation
- the redirection location, if anypublic RedirectException(Throwable cause, int statusCode, String location)
RedirectException
instance with an initial cause. If a non-null
cause is
specified, its message is used to initialize the message of this RedirectException
; otherwise the message
is left blank (null
).cause
- the causestatusCode
- the status codelocation
- the redirection location, if anypublic RedirectException(String msg, Throwable cause, int statusCode, String location)
RedirectException
instance with an initial message and cause.msg
- the messagecause
- the causestatusCode
- the status codelocation
- the redirection location, if anypublic int getStatusCode()
public String getLocation()
Copyright © 2016 JBoss by Red Hat. All rights reserved.