Package io.awspring.cloud.sqs
Class ExceptionUtils
java.lang.Object
io.awspring.cloud.sqs.ExceptionUtils
Utilities to handle exceptions.
- Since:
- 3.4
- Author:
- Tomaz Fernandes
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic Throwable
unwrapException
(Throwable original, Class<? extends Throwable>... exceptionsToUnwrap) Unwraps the original exception until an exception not in the provided exceptions is found.
-
Constructor Details
-
ExceptionUtils
public ExceptionUtils()
-
-
Method Details
-
unwrapException
@SafeVarargs public static Throwable unwrapException(Throwable original, Class<? extends Throwable>... exceptionsToUnwrap) Unwraps the original exception until an exception not in the provided exceptions is found.- Parameters:
original
- the exception to unwrap.exceptionsToUnwrap
- the exceptions from which the original exception should be unwrapped from.- Returns:
- the unwrapped exception.
-