Descriptor::ToNormalizedString

Convert the descriptor to a normalized string. Normalized descriptors have the xpub at the last hardened step. This fails if the provided provider does not have the private keys to derive that xpub.

Synopsis

Declared in <script/descriptor.h>

virtual
bool
ToNormalizedString(
    SigningProvider const& provider,
    std::string& out,
    DescriptorCache const* cache = nullptr) const = 0;

Return Value

True if the normalized string could be produced.

Parameters

NameDescription
provider [in]The SigningProvider to query for private keys.
out [out]The resulting normalized descriptor string.
cache [in]Optional cache supplying the xpub at the last hardened step.