Package jadex.commons
Class MultiException
- java.lang.Object
-
- java.lang.Throwable
-
- java.lang.Exception
-
- java.lang.RuntimeException
-
- jadex.commons.MultiException
-
- All Implemented Interfaces:
java.io.Serializable
public class MultiException extends java.lang.RuntimeException
An exception that can store multiple causes.- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description MultiException()
Create a new multi exception.MultiException(java.lang.String message)
Create a new multi exception.MultiException(java.lang.String message, java.util.List<java.lang.Throwable> causes)
Create a new multi exception.MultiException(java.util.List<java.lang.Throwable> causes)
Create a new multi exception.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
addCause(java.lang.Throwable cause)
Add an exception.java.lang.Throwable[]
getCauses()
Get the causes.java.lang.String
getMessage()
Returns the detail message string of this throwable.void
setText(java.lang.String message)
Set the message.
-
-
-
Constructor Detail
-
MultiException
public MultiException()
Create a new multi exception.
-
MultiException
public MultiException(java.lang.String message)
Create a new multi exception.
-
MultiException
public MultiException(java.util.List<java.lang.Throwable> causes)
Create a new multi exception.
-
MultiException
public MultiException(java.lang.String message, java.util.List<java.lang.Throwable> causes)
Create a new multi exception.
-
-
Method Detail
-
addCause
public void addCause(java.lang.Throwable cause)
Add an exception.- Parameters:
cause
- The cause.
-
getCauses
public java.lang.Throwable[] getCauses()
Get the causes.- Returns:
- The causes.
-
getMessage
public java.lang.String getMessage()
Returns the detail message string of this throwable.- Overrides:
getMessage
in classjava.lang.Throwable
- Returns:
- The detail message string of this
Throwable
instance (which may benull
).
-
setText
public void setText(java.lang.String message)
Set the message.- Parameters:
message
- The message.
-
-