Class ServiceException
java.lang.Object
java.lang.Throwable
java.lang.Exception
java.lang.RuntimeException
com.aquima.interactions.foundation.exception.AppException
com.aquima.interactions.portal.exception.ServiceException
- All Implemented Interfaces:
Serializable
Exception class that can be used in services to indicate that the processing failed.
- Since:
- 5.0
- Author:
- O. Kerpershoek
- See Also:
-
Constructor Summary
ConstructorsConstructorDescriptionServiceException
(String serviceName, IMultilingualText message) Constructs a service exception for a service with a text object explaining the cause of the error.ServiceException
(String serviceName, IMultilingualText message, Throwable error) Constructs a service exception for a service with a text object and a throwable explaining the cause of the error.ServiceException
(String serviceName, String message) -
Method Summary
Modifier and TypeMethodDescriptionThis method returns the multilingual error message of the exception.This method returns the name of the service that generated the exception.Methods inherited from class java.lang.Throwable
addSuppressed, fillInStackTrace, getCause, getLocalizedMessage, getStackTrace, getSuppressed, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString
-
Constructor Details
-
ServiceException
-
ServiceException
Constructs a service exception for a service with a text object explaining the cause of the error.- Parameters:
serviceName
- The name of the service where the error occurred.message
- Text object containing additional information about the cause of the error.
-
ServiceException
Constructs a service exception for a service with a text object and a throwable explaining the cause of the error.- Parameters:
serviceName
- The name of the service where the error occurred.message
- Text object containing additional information about the cause of the error.error
- The original exception (may be null).
-
-
Method Details
-
getServiceName
This method returns the name of the service that generated the exception.- Returns:
- the name of the service that generated the exception.
-
getErrorMessage
This method returns the multilingual error message of the exception.- Returns:
- the multilingual error message of the exception.
-
getMessage
- Overrides:
getMessage
in classThrowable
-