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

Method Iterate

src/validationinterface.cpp:76–87  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

74 }
75
76 template<typename F> void Iterate(F&& f)
77 {
78 WAIT_LOCK(m_mutex, lock);
79 for (auto it = m_list.begin(); it != m_list.end();) {
80 ++it->count;
81 {
82 REVERSE_LOCK(lock);
83 f(*it->callbacks);
84 }
85 it = --it->count ? std::next(it) : m_list.erase(it);
86 }
87 }
88};
89
90static CMainSignals g_signals;

Callers 8

UpdatedBlockTipMethod · 0.45
BlockConnectedMethod · 0.45
BlockDisconnectedMethod · 0.45
ChainStateFlushedMethod · 0.45
BlockCheckedMethod · 0.45
NewPoWValidBlockMethod · 0.45

Calls 3

beginMethod · 0.45
endMethod · 0.45
eraseMethod · 0.45

Tested by

no test coverage detected