CordaRuntimeException

open class CordaRuntimeException(var originalExceptionClassName: String?, _message: String?, _cause: Throwable?) : RuntimeException, CordaThrowable

Base class for all exceptions used for runtime error conditions in Corda.

This is the exception class that is used to throw and handle all exceptions you could encounter at runtime in a flow. This class and subclasses can be serialized by Corda so are safe to throw in flows.

Constructors

Link copied to clipboard
fun CordaRuntimeException(message: String?, cause: Throwable?)

Constructor with just a message and a cause, for rethrowing exceptions that can be serialized.

Link copied to clipboard

Constructor with just a message (creating a fresh execption).

Link copied to clipboard
fun CordaRuntimeException(originalExceptionClassName: String?, _message: String?, _cause: Throwable?)

Constructor used to wrap any execption in a safe way, taking the original exception class name, message and causes as parameters. This can wrap third party exceptions that cannot be serialized.

Functions

Link copied to clipboard
open override fun addSuppressed(suppressed: Array<Throwable>)
Link copied to clipboard
open operator override fun equals(other: Any?): Boolean
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
open override fun hashCode(): Int
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
open override fun setCause(cause: Throwable?)

Allows to set a Throwable as cause after constructing the exception object.

Link copied to clipboard
open override fun setMessage(message: String?)

Allows to set the message after constructing the exception object.

Link copied to clipboard

Properties

Link copied to clipboard
open override val cause: Throwable?
Link copied to clipboard
open override val message: String?
Link copied to clipboard

The name of an exception that isn't serializable and therefore has been caught and converted to an exception in the Corda hierarchy.

Link copied to clipboard
open override val originalMessage: String?

Message of the original exception

Inheritors

Link copied to clipboard