Package com.azure.common.mgmt
Class CloudException
- java.lang.Object
-
- java.lang.Throwable
-
- java.lang.Exception
-
- java.lang.RuntimeException
-
- com.azure.common.exception.AzureException
-
- com.azure.common.exception.ServiceRequestException
-
- com.azure.common.exception.HttpRequestException
-
- com.azure.common.mgmt.CloudException
-
- All Implemented Interfaces:
Serializable
public final class CloudException extends com.azure.common.exception.HttpRequestExceptionException thrown for an invalid response with custom error information.- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description CloudException(String message, com.azure.common.http.HttpResponse response)Initializes a new instance of the CloudException class.CloudException(String message, com.azure.common.http.HttpResponse response, CloudError body)Initializes a new instance of the CloudException class.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description StringtoString()CloudErrorvalue()-
Methods inherited from class java.lang.Throwable
addSuppressed, fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, getSuppressed, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace
-
-
-
-
Constructor Detail
-
CloudException
public CloudException(String message, com.azure.common.http.HttpResponse response)
Initializes a new instance of the CloudException class.- Parameters:
message- the exception message or the response content if a message is not availableresponse- the HTTP response
-
CloudException
public CloudException(String message, com.azure.common.http.HttpResponse response, CloudError body)
Initializes a new instance of the CloudException class.- Parameters:
message- the exception message or the response content if a message is not availableresponse- the HTTP responsebody- the deserialized response body
-
-
Method Detail
-
value
public CloudError value()
- Overrides:
valuein classcom.azure.common.exception.HttpRequestException
-
-