public class RevertReasonExtractor
extends java.lang.Object
| Modifier and Type | Field and Description |
|---|---|
static java.lang.String |
MISSING_REASON |
| Constructor and Description |
|---|
RevertReasonExtractor() |
| Modifier and Type | Method and Description |
|---|---|
static java.lang.String |
extractRevertReason(TransactionReceipt transactionReceipt,
java.lang.String data,
Web3j web3j,
java.lang.Boolean revertReasonCallEnabled)
Extracts the error reason of a reverted transaction (if one exists and enabled).
|
static java.lang.String |
retrieveRevertReason(TransactionReceipt transactionReceipt,
java.lang.String data,
Web3j web3j)
Retrieves the error reason of a reverted transaction (if one exists).
|
public static final java.lang.String MISSING_REASON
public static java.lang.String extractRevertReason(TransactionReceipt transactionReceipt, java.lang.String data, Web3j web3j, java.lang.Boolean revertReasonCallEnabled) throws java.io.IOException
transactionReceipt - the reverted transaction receiptdata - the reverted transaction dataweb3j - Web3j instancerevertReasonCallEnabled - flag of reason retrieval via additional calljava.io.IOException - if the call to the node failspublic static java.lang.String retrieveRevertReason(TransactionReceipt transactionReceipt, java.lang.String data, Web3j web3j) throws java.io.IOException
transactionReceipt - the reverted transaction receiptdata - the reverted transaction dataweb3j - Web3j instancejava.io.IOException - if the call to the node fails