public class ExceptionUnwrapper
extends java.lang.Object
ExceptionWrapper.getCause() method for exceptions that implement the
ExceptionWrapper interface. Does not currently support the Java 1.4
Throwable.getCause() method.| Constructor and Description |
|---|
ExceptionUnwrapper() |
| Modifier and Type | Method and Description |
|---|---|
static java.lang.Exception |
unwrap(java.lang.Exception e)
Unwraps an Exception and returns the underlying Exception, or throws an
Error if the underlying Throwable is an Error.
|
static java.lang.Throwable |
unwrapAny(java.lang.Throwable e)
Unwraps an Exception and returns the underlying Throwable.
|
public static java.lang.Exception unwrap(java.lang.Exception e)
e - is the Exception to unwrap.java.lang.Error - if the underlying Throwable is an Error.java.lang.IllegalArgumentException - if the underlying Throwable is not an
Exception or an Error.public static java.lang.Throwable unwrapAny(java.lang.Throwable e)
e - is the Exception to unwrap.Copyright (c) 1996, 2017 Oracle and/or its affiliates. All rights reserved.