Package org.threadly.util
Class StackSuppressedRuntimeException
- java.lang.Object
-
- java.lang.Throwable
-
- java.lang.Exception
-
- java.lang.RuntimeException
-
- org.threadly.util.StackSuppressedRuntimeException
-
- All Implemented Interfaces:
java.io.Serializable
- Direct Known Subclasses:
CancelDebuggingListenableFuture.FutureProcessingStack
,ExceptionUtils.TransformedSuppressedStackException
public class StackSuppressedRuntimeException extends java.lang.RuntimeException
Type ofRuntimeException
which does not generate a stack at it's point of creation. Generating a stack trace in java is very expensive, and does not always further the understanding of the type of error (particularly when the exception is wrapping another exception, or is a communication of state). In those select conditions using or extending this type of exception can provide a significant performance gain.- Since:
- 5.39 (Existed since 4.8 as SuppressedStackRuntimeException)
- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description StackSuppressedRuntimeException()
Construct a new exception with no message or cause.StackSuppressedRuntimeException(java.lang.String msg)
Construct a new exception with a provided message and no cause.StackSuppressedRuntimeException(java.lang.String msg, java.lang.Throwable cause)
Construct a new exception providing both a unique message and cause.StackSuppressedRuntimeException(java.lang.Throwable cause)
Construct a new exception with a provided cause.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.lang.Throwable
fillInStackTrace()
-
-
-
Constructor Detail
-
StackSuppressedRuntimeException
public StackSuppressedRuntimeException()
Construct a new exception with no message or cause. The cause is not initialized, and may subsequently be initialized by invokingThrowable.initCause(java.lang.Throwable)
.
-
StackSuppressedRuntimeException
public StackSuppressedRuntimeException(java.lang.String msg)
Construct a new exception with a provided message and no cause.- Parameters:
msg
- The message which can later be retrieved byThrowable.getMessage()
-
StackSuppressedRuntimeException
public StackSuppressedRuntimeException(java.lang.Throwable cause)
Construct a new exception with a provided cause. The message will be defaulted from the cause provided.- Parameters:
cause
- The cause which contributed to this exception
-
StackSuppressedRuntimeException
public StackSuppressedRuntimeException(java.lang.String msg, java.lang.Throwable cause)
Construct a new exception providing both a unique message and cause.- Parameters:
msg
- The message which can later be retrieved byThrowable.getMessage()
cause
- The cause which contributed to this exception
-
-