Load an existing wallet from disk into the context.

Synopsis

Declared in <wallet/wallet.h>

std::shared_ptr<CWallet>
LoadWallet(
    WalletContext& context,
    std::string const& name,
    std::optional<bool> load_on_start,
    DatabaseOptions const& options,
    DatabaseStatus& status,
    bilingual_str& error,
    std::vector<bilingual_str>& warnings);

Return Value

The loaded wallet, or nullptr on failure.

Parameters

Name

Description

context

The wallet context to load into.

name

The wallet name to load.

load_on_start

Optionally set whether the wallet loads on startup.

options

Database options used to open the wallet.

status

Set to the database open status.

error

Set to an error message on failure.

warnings

Warnings produced while loading.

Created with MrDocs