MCPcopy Create free account
hub / github.com/chain/Core / writeTo

Method writeTo

protocol/bc/legacy/block_commitment.go:38–49  ·  view source on GitHub ↗
(w io.Writer)

Source from the content-addressed store, hash-verified

36}
37
38func (bc *BlockCommitment) writeTo(w io.Writer) error {
39 _, err := bc.TransactionsMerkleRoot.WriteTo(w)
40 if err != nil {
41 return err
42 }
43 _, err = bc.AssetsMerkleRoot.WriteTo(w)
44 if err != nil {
45 return err
46 }
47 _, err = blockchain.WriteVarstr31(w, bc.ConsensusProgram)
48 return err
49}

Callers

nothing calls this directly

Calls 1

WriteToMethod · 0.45

Tested by

no test coverage detected