43 argsman.
AddArg(
"-avoidpartialspends",
strprintf(
"Group outputs by address, selecting all or none, instead of selecting on a per-output basis. Privacy is improved as an address is only used once (unless someone sends to it after spending from it), but may result in slightly higher fees as suboptimal coin selection may result due to the added limitation (default: %u (always enabled for wallets with \"avoid_reuse\" enabled))",
DEFAULT_AVOIDPARTIALSPENDS),
ArgsManager::ALLOW_ANY,
OptionsCategory::WALLET);
44 argsman.
AddArg(
"-changetype",
"What type of change to use (\"legacy\", \"p2sh-segwit\", or \"bech32\"). Default is same as -addresstype, except when -addresstype=p2sh-segwit a native segwit output is used when sending to a native segwit address)",
ArgsManager::ALLOW_ANY,
OptionsCategory::WALLET);
46 argsman.
AddArg(
"-discardfee=<amt>",
strprintf(
"The fee rate (in %s/kB) that indicates your tolerance for discarding change by adding it to the fee (default: %s). "
47 "Note: An output is discarded if it is dust at this rate, but we will always discard up to the dust relay fee and a discard fee above that is limited by the fee estimate for the longest target",
50 argsman.
AddArg(
"-fallbackfee=<amt>",
strprintf(
"A fee rate (in %s/kB) that will be used when fee estimation has insufficient data. 0 to entirely disable the fallbackfee feature. (default: %s)",
54 argsman.
AddArg(
"-maxtxfee=<amt>",
strprintf(
"Maximum total fees (in %s) to use in a single wallet transaction; setting this too low may abort large transactions (default: %s)",
56 argsman.
AddArg(
"-mintxfee=<amt>",
strprintf(
"Fees (in %s/kB) smaller than this are considered zero fee for transaction creation (default: %s)",
58 argsman.
AddArg(
"-paytxfee=<amt>",
strprintf(
"Fee (in %s/kB) to add to transactions you send (default: %s)",
63 argsman.
AddArg(
"-wallet=<path>",
"Specify wallet path to load at startup. Can be used multiple times to load multiple wallets. Path is to a directory containing wallet data and log files. If the path is not absolute, it is interpreted relative to <walletdir>. This only loads existing wallets and does not create new ones. For backwards compatibility this also accepts names of existing top-level data files in <walletdir>.",
ArgsManager::ALLOW_ANY |
ArgsManager::NETWORK_ONLY,
OptionsCategory::WALLET);
67 argsman.
AddArg(
"-walletnotify=<cmd>",
"Execute command when a wallet transaction changes. %s in cmd is replaced by TxID and %w is replaced by wallet name. %w is not currently implemented on windows. On systems where %w is supported, it should NOT be quoted because this would break shell escaping used to invoke the command.",
ArgsManager::ALLOW_ANY,
OptionsCategory::WALLET);
82 for (
const std::string& wallet :
gArgs.
GetArgs(
"-wallet")) {
83 LogPrintf(
"%s: parameter interaction: -disablewallet -> ignoring -wallet=%s\n", __func__, wallet);
90 LogPrintf(
"%s: parameter interaction: -blocksonly=1 -> setting -walletbroadcast=0\n", __func__);
94 return InitError(
Untranslated(
"-zapwallettxes has been removed. If you are attempting to remove a stuck transaction from your wallet, please use abandontransaction instead."));
98 return InitError(
Untranslated(
"-sysperms is not allowed in combination with enabled wallet functionality"));
static const unsigned int DEFAULT_WALLET_DBLOGSIZE
static const bool DEFAULT_WALLET_PRIVDB
#define Assert(val)
Identity function.
std::vector< std::string > GetArgs(const std::string &strArg) const
Return a vector of strings of the given argument.
bool IsArgSet(const std::string &strArg) const
Return true if the given argument has been manually set.
bool SoftSetBoolArg(const std::string &strArg, bool fValue)
Set a boolean argument if it doesn't already have a value.
bool GetBoolArg(const std::string &strArg, bool fDefault) const
Return boolean argument or default value.
void AddHiddenArgs(const std::vector< std::string > &args)
Add many hidden arguments.
void AddArg(const std::string &name, const std::string &help, unsigned int flags, const OptionsCategory &cat)
Add argument.
Fee rate in satoshis per kilobyte: CAmount / kB.
void Construct(NodeContext &node) const override
Add wallets that should be opened to list of chain clients.
bool ParameterInteraction() const override
Wallets parameter interaction.
void AddWalletOptions(ArgsManager &argsman) const override
Return the wallets help message.
bool HasWalletSupport() const override
Was the wallet component compiled in.
static constexpr bool DEFAULT_AVOIDPARTIALSPENDS
Default for -avoidpartialspends.
const std::string CURRENCY_UNIT
static void LogPrintf(const char *fmt, const Args &... args)
std::string FormatMoney(const CAmount &n)
Money parsing/formatting utilities.
std::unique_ptr< WalletClient > MakeWalletClient(Chain &chain, ArgsManager &args)
Return implementation of ChainClient interface for a wallet client.
static const bool DEFAULT_BLOCKSONLY
Default for blocks only.
const std::string & FormatOutputType(OutputType type)
static const unsigned int DEFAULT_KEYPOOL_SIZE
Default for -keypool.
NodeContext struct containing references to chain state and connection state.
std::unique_ptr< interfaces::Chain > chain
interfaces::WalletClient * wallet_client
Reference to chain client that should used to load or create wallets opened by the gui.
std::vector< std::unique_ptr< interfaces::ChainClient > > chain_clients
List of all chain clients (wallet processes or other client) connected to node.
bilingual_str Untranslated(std::string original)
Mark a bilingual_str as untranslated.
bool InitError(const bilingual_str &str)
Show error message.
const WalletInitInterface & g_wallet_init_interface
static const bool DEFAULT_DISABLE_WALLET
constexpr OutputType DEFAULT_ADDRESS_TYPE
Default for -addresstype.
static const unsigned int DEFAULT_TX_CONFIRM_TARGET
-txconfirmtarget default
constexpr CAmount DEFAULT_TRANSACTION_MAXFEE
-maxtxfee default
static const bool DEFAULT_SPEND_ZEROCONF_CHANGE
Default for -spendzeroconfchange.
static const CAmount DEFAULT_MAX_AVOIDPARTIALSPEND_FEE
maximum fee increase allowed to do partial spend avoidance, even for nodes with this feature disabled...
static const bool DEFAULT_WALLETBROADCAST
static const CAmount DEFAULT_DISCARD_FEE
-discardfee default
static const bool DEFAULT_WALLET_REJECT_LONG_CHAINS
Default for -walletrejectlongchains.
static const CAmount DEFAULT_FALLBACK_FEE
-fallbackfee default
static const bool DEFAULT_WALLET_RBF
-walletrbf default
constexpr CAmount DEFAULT_PAY_TX_FEE
-paytxfee default
static const CAmount DEFAULT_TRANSACTION_MINFEE
-mintxfee default
static const bool DEFAULT_FLUSHWALLET
Overview of wallet database classes: