unlockingScript

open fun unlockingScript(vararg params: ByteArray): SatoshiScript

Create a spend (input) script that will satisfy the constraints specified by the lockingScript and the templateScript (if applicable). This script will contain the redeemScript in the P2SH case.

Parameters

params

provide needed, script-specific args in the params field, like the signature


open fun unlockingScript(flatTx: ByteArray, inputIdx: Long, sigHashType: ByteArray, inputAmount: Long, spendingProposal: SpendingProposal? = null): SatoshiScript

Create a spend (input) script that will satisfy the constraints specified by the lockingScript and the templateScript (if applicable). This script will contain the redeemScript in the P2SH case. Many scripts require signatures. This API provides the data needed for this class to craft signatures, and provides additional derived-class defined params.

Parameters

spendingProposal

If this destination requires additional information to spend (atomicSpending == false), you cannot successfully call unlockingScript until you have a completed SpendingProposal