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

Method getLastBlockTime

src/node/interfaces.cpp:232–239  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

230 return tip ? tip->GetBlockHash() : Params().GenesisBlock().GetHash();
231 }
232 int64_t getLastBlockTime() override
233 {
234 LOCK(::cs_main);
235 if (chainman().ActiveChain().Tip()) {
236 return chainman().ActiveChain().Tip()->GetBlockTime();
237 }
238 return Params().GenesisBlock().GetBlockTime(); // Genesis block's time of current network
239 }
240 double getVerificationProgress() override
241 {
242 const CBlockIndex* tip;

Callers

nothing calls this directly

Calls 3

ParamsClass · 0.70
TipMethod · 0.45
GetBlockTimeMethod · 0.45

Tested by

no test coverage detected