MCPcopy Create free account
hub / github.com/ElementsProject/elements / handleNotifyHeaderTip

Method handleNotifyHeaderTip

src/node/interfaces.cpp:330–337  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

328 }));
329 }
330 std::unique_ptr<Handler> handleNotifyHeaderTip(NotifyHeaderTipFn fn) override
331 {
332 return MakeHandler(
333 ::uiInterface.NotifyHeaderTip_connect([fn](SynchronizationState sync_state, const CBlockIndex* block) {
334 fn(sync_state, BlockTip{block->nHeight, block->GetBlockTime(), block->GetBlockHash()},
335 /* verification progress is unused when a header was received */ 0);
336 }));
337 }
338 NodeContext* context() override { return m_context; }
339 void setContext(NodeContext* context) override
340 {

Callers 1

Calls 4

MakeHandlerFunction · 0.85
fnFunction · 0.85
GetBlockTimeMethod · 0.45
GetBlockHashMethod · 0.45

Tested by

no test coverage detected