MCPcopy Create free account
hub / github.com/bitcoin/bitcoin / OriginString

Method OriginString

src/script/descriptor.cpp:261–266  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

259 bool m_apostrophe;
260
261 std::string OriginString(StringType type, bool normalized=false) const
262 {
263 // If StringType==COMPAT, always use the apostrophe to stay compatible with previous versions
264 bool use_apostrophe = (!normalized && m_apostrophe) || type == StringType::COMPAT;
265 return HexStr(m_origin.fingerprint) + FormatHDKeypath(m_origin.path, use_apostrophe);
266 }
267
268public:
269 OriginPubkeyProvider(uint32_t exp_index, KeyOriginInfo info, std::unique_ptr<PubkeyProvider> provider, bool apostrophe) : PubkeyProvider(exp_index), m_origin(std::move(info)), m_provider(std::move(provider)), m_apostrophe(apostrophe) {}

Callers

nothing calls this directly

Calls 2

FormatHDKeypathFunction · 0.85
HexStrFunction · 0.50

Tested by

no test coverage detected