MCPcopy Create free account
hub / github.com/BTCGPU/BTCGPU / listCoins

Method listCoins

src/interfaces/wallet.cpp:385–397  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

383 return m_wallet.GetCredit(txout, filter);
384 }
385 CoinsList listCoins() override
386 {
387 LOCK2(::cs_main, m_wallet.cs_wallet);
388 CoinsList result;
389 for (const auto& entry : m_wallet.ListCoins()) {
390 auto& group = result[entry.first];
391 for (const auto& coin : entry.second) {
392 group.emplace_back(
393 COutPoint(coin.tx->GetHash(), coin.i), MakeWalletTxOut(m_wallet, *coin.tx, coin.i, coin.nDepth));
394 }
395 }
396 return result;
397 }
398 std::vector<WalletTxOut> getCoins(const std::vector<COutPoint>& outputs) override
399 {
400 LOCK2(::cs_main, m_wallet.cs_wallet);

Callers 1

updateViewMethod · 0.80

Calls 4

MakeWalletTxOutFunction · 0.85
ListCoinsMethod · 0.80
COutPointClass · 0.50
GetHashMethod · 0.45

Tested by

no test coverage detected