clementine_core::builder::transaction::operator_assert

Function create_mini_asserts

Source
pub fn create_mini_asserts(
    kickoff_txhandler: &TxHandler,
    num_asserts: usize,
    paramset: &'static ProtocolParamset,
) -> Result<Vec<TxHandler>, BridgeError>
Expand description

Creates a vector of TxHandler for mini_assert transactions.

These transactions are used to commit BitVM assertions of operator’s proof that it paid the payout corresponding to the deposit.

§Inputs

  1. KickoffTx: Assert utxo (per mini assert)

§Outputs

  1. Anchor output for CPFP
  2. Dummy OP_RETURN output (to pad the size of the transaction, as it is too small otherwise)

§Arguments

  • kickoff_txhandler - The kickoff transaction handler providing the input.
  • num_asserts - Number of mini assert transactions to create.

§Returns

A vector of TxHandler for mini assert transactions, or a BridgeError if construction fails.