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

Method GetLegacyScriptPubKeyMan

src/wallet/wallet.cpp:3475–3485  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

3473}
3474
3475LegacyScriptPubKeyMan* CWallet::GetLegacyScriptPubKeyMan() const
3476{
3477 if (IsWalletFlagSet(WALLET_FLAG_DESCRIPTORS)) {
3478 return nullptr;
3479 }
3480 // Legacy wallets only have one ScriptPubKeyMan which is a LegacyScriptPubKeyMan.
3481 // Everything in m_internal_spk_managers and m_external_spk_managers point to the same legacyScriptPubKeyMan.
3482 auto it = m_internal_spk_managers.find(OutputType::LEGACY);
3483 if (it == m_internal_spk_managers.end()) return nullptr;
3484 return dynamic_cast<LegacyScriptPubKeyMan*>(it->second);
3485}
3486
3487LegacyScriptPubKeyMan* CWallet::GetOrCreateLegacyScriptPubKeyMan()
3488{

Callers 15

feebumper.cppFile · 0.80
CheckFeeRateFunction · 0.80
spend.cppFile · 0.80
LoadWalletMethod · 0.80
haveWatchOnlyMethod · 0.80
BOOST_AUTO_TEST_CASEFunction · 0.80
getnewaddressFunction · 0.80
getrawchangeaddressFunction · 0.80
getbalancesFunction · 0.80
getwalletinfoFunction · 0.80
signblockFunction · 0.80

Calls 2

findMethod · 0.80
endMethod · 0.45

Tested by 1

BOOST_AUTO_TEST_CASEFunction · 0.64