Instance Method
readBlockSpentOutputs(at:)
Reads the spent outputs (undo data) for a block from disk — the collection of UTXOs that this block consumed.
func readBlockSpentOutputs(at entry: BlockTreeEntry) -> BlockSpentOutputs?
Parameters
-
entry
-
The block tree entry pointing to the block.
Return Value
The block’s spent outputs, or nil on read failure.
Discussion
Spent-output data is what lets the kernel undo a block during a reorg. Returns nil for the genesis block (no inputs spent, no undo data written) and when the undo file is not present on disk.