public class MultiThrowable extends Throwable
This class is NOT threadsafe.
Constructor and Description |
---|
MultiThrowable() |
Modifier and Type | Method and Description |
---|---|
void |
add(Throwable t)
Add a throwable to the list of wrapped throwables.
|
Throwable |
getThrowable() |
List<Throwable> |
getThrowables() |
int |
size() |
String |
toString()
Overrides the default implementation to provide a concatenation of the
messages associated with each of the wrapped throwables.
|
addSuppressed, fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, getSuppressed, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace
public void add(Throwable t)
t
- The throwable to addpublic List<Throwable> getThrowables()
public Throwable getThrowable()
null
if there are no wrapped throwables, the Throwable if
there is a single wrapped throwable or the current instance of
there are multiple wrapped throwablespublic int size()
public String toString()
Copyright © 2000-2021 Apache Software Foundation. All Rights Reserved.