Structure
BlockTreeEntrySnapshot
An owned snapshot of a BlockTreeEntry’s data — three fields (height, block hash, block header) captured as Swift-owned values.
struct BlockTreeEntrySnapshot
Mentioned In
Overview
Unlike BlockTreeEntry (a view type whose pointer lifetime is tied to ChainstateManager), a snapshot owns all its data and is safe to store indefinitely, pass across tasks, and capture in closures.
Used primarily by kernel notification callbacks (blockTip, blockConnected etc.), where the underlying C pointer is only valid during the callback invocation. Promote any BlockTreeEntry to a snapshot before escaping the callback scope.
Topics
Instance Properties