findInputs

fun findInputs(amountSatoshis: Long, minConfirms: Int = 0, contractId: ByteArray? = null, filter: (Spendable) -> Long? = null): MutableList<Spendable>?

Find ungrouped inputs in this wallet to use in a new transaction. To be viable, the input needs to actually be spendable (have a backing pay destination). This DOES mark them as used, so can be called repeatedly.

Parameters

amountSatoshis

: The quantity of satoshis needed. Pass LONG.MAX_VALUE to get all of them (otherwise the function will fail if there are not enough)

minConfirms

: Minimum number of confirmations

contractId

(default null). Only use inputs that match this contract id, or if null, have no associated contract.

filter

: You can eliminate some inputs using this filter, by returning 0 Pass a filter to select a subset of the available UTXOs.