public class ClassNotFoundRuntimeException extends RuntimeException
ClassNotFoundException
.
This exception is typically used to convert a checked exception (ClassNotFoundException) into an unchecked exception, allowing it to propagate up the call stack without the need for explicit exception handling.
RuntimeException
,
ClassNotFoundException
,
Serialized FormConstructor and Description |
---|
ClassNotFoundRuntimeException(ClassNotFoundException cause)
Constructs a new runtime exception with the specified cause.
|
Modifier and Type | Method and Description |
---|---|
ClassNotFoundException |
getCause()
Returns the
ClassNotFoundException that is the cause of this runtime exception. |
addSuppressed, fillInStackTrace, getLocalizedMessage, getMessage, getStackTrace, getSuppressed, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString
public ClassNotFoundRuntimeException(ClassNotFoundException cause)
cause
- The ClassNotFoundException
to be wrapped by this runtime exception.public ClassNotFoundException getCause()
ClassNotFoundException
that is the cause of this runtime exception.Copyright © 2023. All rights reserved.