MCPcopy Create free account
hub / github.com/chain/txvm / SpendMultisig

Function SpendMultisig

protocol/txbuilder/standard/input.go:42–53  ·  view source on GitHub ↗

SpendMultisig writes txvm bytecode to b, spending a value previously locked with the standard pay-to-multisig-program contract.

(
	b *txvmutil.Builder,
	quorum int,
	pubkeys []ed25519.PublicKey,
	amount int64,
	assetID bc.Hash,
	anchor []byte,
	seed []byte, // PayToMultisigSeed1[:] or PayToMultisigSeed2[:]
)

Source from the content-addressed store, hash-verified

40// previously locked with the standard pay-to-multisig-program
41// contract.
42func SpendMultisig(
43 b *txvmutil.Builder,
44 quorum int,
45 pubkeys []ed25519.PublicKey,
46 amount int64,
47 assetID bc.Hash,
48 anchor []byte,
49 seed []byte, // PayToMultisigSeed1[:] or PayToMultisigSeed2[:]
50) {
51 Snapshot(b, quorum, pubkeys, amount, assetID, anchor, seed)
52 b.Op(op.Input).Op(op.Call)
53}
54
55// Snapshot adds to b the snapshot of a pay-to-multisig-program contract as it appears in the UTXO set.
56func Snapshot(b *txvmutil.Builder,

Callers 2

materializeTxMethod · 0.92
TestProgCreationFunction · 0.85

Calls 2

OpMethod · 0.80
SnapshotFunction · 0.70

Tested by 1

TestProgCreationFunction · 0.68