RuntimeErrorException (Java SE 15 & JDK 15) (original) (raw)
All Implemented Interfaces:
[Serializable](../../../java.base/java/io/Serializable.html "interface in java.io")
public class RuntimeErrorException extends JMRuntimeException
When a java.lang.Error
occurs in the agent it should be caught and re-thrown as a RuntimeErrorException
.
Since:
1.5
See Also:
Constructor Summary
Constructors
Constructor | Description |
---|---|
RuntimeErrorException(Error e) | Default constructor. |
RuntimeErrorException(Error e,String message) | Constructor that allows a specific error message to be specified. |
Method Summary
Methods declared in class java.lang.Throwable
[addSuppressed](../../../java.base/java/lang/Throwable.html#addSuppressed%28java.lang.Throwable%29), [fillInStackTrace](../../../java.base/java/lang/Throwable.html#fillInStackTrace%28%29), [getLocalizedMessage](../../../java.base/java/lang/Throwable.html#getLocalizedMessage%28%29), [getMessage](../../../java.base/java/lang/Throwable.html#getMessage%28%29), [getStackTrace](../../../java.base/java/lang/Throwable.html#getStackTrace%28%29), [getSuppressed](../../../java.base/java/lang/Throwable.html#getSuppressed%28%29), [initCause](../../../java.base/java/lang/Throwable.html#initCause%28java.lang.Throwable%29), [printStackTrace](../../../java.base/java/lang/Throwable.html#printStackTrace%28%29), [printStackTrace](../../../java.base/java/lang/Throwable.html#printStackTrace%28java.io.PrintStream%29), [printStackTrace](../../../java.base/java/lang/Throwable.html#printStackTrace%28java.io.PrintWriter%29), [setStackTrace](../../../java.base/java/lang/Throwable.html#setStackTrace%28java.lang.StackTraceElement%5B%5D%29), [toString](../../../java.base/java/lang/Throwable.html#toString%28%29)
Constructor Details
RuntimeErrorException
public RuntimeErrorException(Error e)
Default constructor.
Parameters:
e
- the wrapped error.RuntimeErrorException
public RuntimeErrorException(Error e,String message)
Constructor that allows a specific error message to be specified.
Parameters:
e
- the wrapped error.
message
- the detail message.Method Details
getTargetError
public Error getTargetError()
Returns the actual Error thrown.
Returns:
the wrapped Error.getCause
Returns the actual Error thrown.
Overrides:
[getCause](../../../java.base/java/lang/Throwable.html#getCause%28%29)
in class[Throwable](../../../java.base/java/lang/Throwable.html "class in java.lang")
Returns:
the wrapped Error.