java.lang.Object
java.lang.Throwable
java.lang.Exception
java.lang.RuntimeException
io.helidon.webclient.WebClientException
- All Implemented Interfaces:
Serializable
An exception that caused this client request to fail. If the exception is based on status or content of response from
server, the
WebClientResponse
is available to obtain any needed details.
If the exception was caused before data was sent, or due to timeouts, socket exceptions etc., the WebClientResponse
is
not present and exception handling must be based on the wrapped exception.- See Also:
-
Constructor Summary
ConstructorDescriptionWebClientException
(String message) Creates new instance of web client exception. -
Method Summary
Modifier and TypeMethodDescriptionresponse()
WebClientResponse
that caused this exception if caused by response from server.Methods inherited from class java.lang.Throwable
addSuppressed, fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, getSuppressed, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString
-
Constructor Details
-
WebClientException
Creates new instance of web client exception.- Parameters:
message
- exception message
-
-
Method Details
-
response
WebClientResponse
that caused this exception if caused by response from server. Otherwise an emptyOptional
.- Returns:
- ClientResponse if this client request reached the moment when a response is received.
-