Class AsyncSDKError
- java.lang.Object
-
- java.lang.Throwable
-
- java.lang.Exception
-
- java.lang.RuntimeException
-
- com.stackone.stackone_client_java.models.errors.StackOneError
-
- com.stackone.stackone_client_java.models.errors.AsyncSDKError
-
- All Implemented Interfaces:
java.io.Serializable
public class AsyncSDKError extends StackOneError
Thrown by an async service call when an error response occurs. Contains details about the response. This is an unchecked exception suitable for use in CompletableFuture chains.- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description AsyncSDKError(java.lang.String message, int code, byte[] body, java.net.http.HttpResponse<Blob> rawResponse, java.lang.Throwable cause)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.net.http.HttpResponse<Blob>rawResponse()Returns the raw HTTP response associated with this exception.-
Methods inherited from class com.stackone.stackone_client_java.models.errors.StackOneError
body, bodyAsString, code, headers, message, toString, withBody, withCode, withRawResponse
-
-
-
-
Constructor Detail
-
AsyncSDKError
public AsyncSDKError(java.lang.String message, int code, @Nullable byte[] body, java.net.http.HttpResponse<Blob> rawResponse, @Nullable java.lang.Throwable cause)
-
-
Method Detail
-
rawResponse
public java.net.http.HttpResponse<Blob> rawResponse()
Description copied from class:StackOneErrorReturns the raw HTTP response associated with this exception. The response body stream may not be available (but the body can be accessed via thebody()method).- Overrides:
rawResponsein classStackOneError- Returns:
- the raw HTTP response
-
-