Class ServiceException
java.lang.Object
java.lang.Throwable
java.lang.Exception
java.lang.RuntimeException
com.atlassian.confluence.api.service.exceptions.ServiceException
- All Implemented Interfaces:
Serializable
- Direct Known Subclasses:
BadRequestException
,ConflictException
,GoneException
,IllegalURLException
,InternalServerException
,LicenseUnavailableException
,NotAuthenticatedException
,NotFoundException
,NotImplementedServiceException
,PermissionException
,ReadOnlyException
,SeeOtherException
All thrown API Service-level exceptions should extend this exception.
Every ServiceException subclass should have a clean mapping to HTTP response statuses and messages.
Services may throw this exception to wrap general unexpected exceptions; instances of this base class (rather than a subclass) map to a http 500 error.
ServiceExceptions can handle the case where multiple validation errors occur - use the
constructor accepting ValidationResult
, and they will all be returned to the client.
- See Also:
-
Constructor Summary
ConstructorsConstructorDescriptionServiceException
(String message) ServiceException
(String message, ValidationResult validationResult) ServiceException
(String message, Throwable cause) ServiceException
(Throwable throwable) -
Method Summary
Methods inherited from class java.lang.Throwable
addSuppressed, fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, getSuppressed, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace