Package com.microsoft.azure.storage.blob
Class StorageException
- java.lang.Object
-
- java.lang.Throwable
-
- java.lang.Exception
-
- java.lang.RuntimeException
-
- com.microsoft.rest.v2.RestException
-
- com.microsoft.azure.storage.blob.StorageException
-
- All Implemented Interfaces:
Serializable
public final class StorageException extends com.microsoft.rest.v2.RestExceptionAStorageExceptionis thrown whenever Azure Storage successfully returns an error code that is not 200-level. Users can inspect the status code and error code to determine the cause of the error response. The exception message may also contain more detailed information depending on the type of error. The user may also inspect the raw HTTP response or call toString to get the full payload of the error response if present. Note that even some expected "errors" will be thrown as aStorageException. For example, some users may perform a getProperties request on an entity to determine whether it exists or not. If it does not exists, an exception will be thrown even though this may be considered an expected indication of absence in this case.- See Also:
- Serialized Form
-
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description StorageErrorCodeerrorCode()Stringmessage()intstatusCode()-
Methods inherited from class java.lang.Throwable
addSuppressed, fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, getSuppressed, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString
-
-
-
-
Method Detail
-
errorCode
public StorageErrorCode errorCode()
- Returns:
- The error code returned by the service.
-
message
public String message()
- Returns:
- The message returned by the service.
-
statusCode
public int statusCode()
- Returns:
- The status code on the response.
-
-