witness2 method

Transaction witness2(
  1. Transaction r2,
  2. Transaction r1, {
  3. PoolHeader? header,
  4. ({List<int> outpoint, List<int> parts, Transaction tx})? next,
  5. List<int>? bundles,
})

Implementation

Transaction witness2(Transaction r2, Transaction r1,
    {PoolHeader? header, ({Transaction tx, List<int> outpoint, List<int> parts})? next, List<int>? bundles}) {
  final y = next ?? y2;
  return svc.createWitnessTxn(signer, fundingB, r2, hex.decode(r1.serialize()), opPub, opPKH, ShieldedPoolAction.ROUND,
      newOwnerPKH: hex.decode(opPKH),
      newHeader: (header ?? f.h2).encode(),
      nextSlot: y.outpoint,
      slotParts: y.parts,
      verifierBody: f.body,
      bundles: bundles ?? f.bundles2,
      withdrawals: [f.withdrawal]);
}