A lightweight client for keeping in sync with chain activity.
Defines an [SpvClient] utility for polling one or more block sources for the best chain tip.
It is used to notify listeners of blocks connected or disconnected since the last poll. Useful
for keeping a Lightning node in sync with the chain.
Defines a [BlockSource] trait, which is an asynchronous interface for retrieving block headers
and data.
Enabling feature rest-client or rpc-client allows configuring the client to fetch blocks
using Bitcoin Core's REST or RPC interface, respectively.
Both features support either blocking I/O using std::net::TcpStream or, with feature tokio,
non-blocking I/O using tokio::net::TcpStream from inside a Tokio runtime.