corda / net.corda.finance.workflows.asset / ObligationUtils / generateExit

generateExit

@JvmStatic fun <P : Any> generateExit(tx: TransactionBuilder, amountIssued: Amount<Issued<Terms<P>>>, assetStates: List<StateAndRef<State<P>>>): Set<PublicKey>

Generate an transaction exiting an obligation from the ledger.

Parameters

tx - transaction builder to add states and commands to.

amountIssued - the amount to be exited, represented as a quantity of issued currency.

assetStates - the asset states to take funds from. No checks are done about ownership of these states, it is the responsibility of the caller to check that they do not exit funds held by others.

Return
the public keys which must sign the transaction for it to be valid.