public class TransactionExecutionException
extends java.lang.Exception
The other attributes of a Java exception — a stack trace, a cause, suppressed exceptions — are not saved in the database and are used for logging only.
An external client will get the error code and description when requests a transaction status of a failed transaction. See the API endpoint documentation for more information.
| Constructor and Description |
|---|
TransactionExecutionException(byte errorCode)
Constructs a new transaction exception with no description.
|
TransactionExecutionException(byte errorCode,
java.lang.String description)
Constructs a new transaction exception with the specified description.
|
TransactionExecutionException(byte errorCode,
java.lang.String description,
java.lang.Throwable cause)
Constructs a new transaction exception with the specified description and cause.
|
| Modifier and Type | Method and Description |
|---|---|
byte |
getErrorCode()
Returns the transaction error code.
|
java.lang.String |
toString()
Returns a string representation of this error.
|
public TransactionExecutionException(byte errorCode)
errorCode - the transaction error codepublic TransactionExecutionException(byte errorCode,
@Nullable
java.lang.String description)
errorCode - the transaction error codedescription - the error description. The detail description is saved for
later retrieval by the Throwable.getMessage() method.public TransactionExecutionException(byte errorCode,
@Nullable
java.lang.String description,
@Nullable
java.lang.Throwable cause)
Note that the detail message associated with cause is not automatically
incorporated in this exception’s detail message.
errorCode - the transaction error codedescription - the error description. The detail description is saved for
later retrieval by the Throwable.getMessage() method.cause - the cause (which is saved for later retrieval by the Throwable.getCause() method).
A null value is permitted, and indicates that the cause is nonexistent or unknown.public final byte getErrorCode()
public java.lang.String toString()
toString in class java.lang.ThrowableCopyright © 2018 Exonum. All rights reserved.