Interface UtxoTransactionValidator
-
- All Implemented Interfaces:
-
java.io.Serializable
@FunctionalInterface() public interface UtxoTransactionValidator implements Serializable
Defines a functional interface that validates a UtxoLedgerTransaction.
An implementation of UtxoTransactionValidator can be passed to receiveFinality to perform custom validation on the UtxoLedgerTransaction received from the initiator of finality.
When validating a UtxoLedgerTransaction, throw either an IllegalArgumentException, IllegalStateException or CordaRuntimeException to indicate that the transaction is invalid.
This will lead to the termination of finality for the caller of receiveFinality and all participants included in finalizing the transaction.
Other exceptions will still stop the progression of finality; however, the reason for the failure will not be communicated to the initiator of finality.
-
-
Method Summary
Modifier and Type Method Description abstract void
checkTransaction(@NotNull() UtxoLedgerTransaction transaction)
Checks a UtxoLedgerTransaction for validity. -
-
Method Detail
-
checkTransaction
@Suspendable() abstract void checkTransaction(@NotNull() UtxoLedgerTransaction transaction)
Checks a UtxoLedgerTransaction for validity.
Throw an IllegalArgumentException, IllegalStateException or CordaRuntimeException to indicate that the transaction is invalid.
- Parameters:
transaction
- The transaction to check.
-
-
-
-