public LedgerDSLInterpreter<T extends TransactionDSLInterpreter> extends Verifies, OutputStateLookup
This interface defines the bare bone functionality that a Ledger DSL interpreter should implement.
TODO (Kotlin 1.1): Use type synonyms to make the type params less unwieldy
Verifies.DefaultImpls
Modifier and Type | Method and Description |
---|---|
WireTransaction |
_transaction(java.lang.String transactionLabel,
TransactionBuilder transactionBuilder,
Function1<? super T,? extends net.corda.testing.dsl.EnforceVerifyOrFail> dsl)
Creates and adds a transaction to the ledger.
|
void |
_tweak(Function1<? super net.corda.testing.dsl.LedgerDSLInterpreter<? extends T>,Unit> dsl)
Creates a local scoped copy of the ledger.
|
WireTransaction |
_unverifiedTransaction(java.lang.String transactionLabel,
TransactionBuilder transactionBuilder,
Function1<? super T,Unit> dsl)
Creates and adds a transaction to the ledger that will not be verified by
Verifies.verifies . |
SecureHash |
attachment(java.io.InputStream attachment)
Adds an attachment to the ledger.
|
fails, fails with, failsWith, verifies
retrieveOutputStateAndRef
WireTransaction _transaction(java.lang.String transactionLabel, TransactionBuilder transactionBuilder, Function1<? super T,? extends net.corda.testing.dsl.EnforceVerifyOrFail> dsl)
Creates and adds a transaction to the ledger.
transactionLabel
- Optional label of the transaction, to be used in diagnostic messages.transactionBuilder
- The base transactionBuilder that will be used to build the transaction.dsl
- The dsl that should be interpreted for building the transaction.class WireTransaction
of the built transaction.WireTransaction _unverifiedTransaction(java.lang.String transactionLabel, TransactionBuilder transactionBuilder, Function1<? super T,Unit> dsl)
Creates and adds a transaction to the ledger that will not be verified by Verifies.verifies
.
transactionLabel
- Optional label of the transaction, to be used in diagnostic messages.transactionBuilder
- The base transactionBuilder that will be used to build the transaction.dsl
- The dsl that should be interpreted for building the transaction.class WireTransaction
of the built transaction.Verifies.verifies
void _tweak(Function1<? super net.corda.testing.dsl.LedgerDSLInterpreter<? extends T>,Unit> dsl)
Creates a local scoped copy of the ledger.
dsl
- The ledger DSL to be interpreted using the copy.SecureHash attachment(java.io.InputStream attachment)
Adds an attachment to the ledger.
attachment
- The InputStream defining the contents of the attachment.class SecureHash
that identifies the attachment, to be used in transactions.