wallet::CoinSelectionParams

Parameters for one iteration of Coin Selection.

Synopsis

Declared in <wallet/coinselection.h>

struct CoinSelectionParams;

Member Functions

NameDescription
CoinSelectionParams [constructor]Constructors

Data Members

NameDescription
change_output_size Size of a change output in bytes, determined by the output type.
change_spend_size Size of the input to spend a change output in virtual bytes.
m_avoid_partial_spends When true, always spend all (up to OUTPUT_GROUP_MAX_ENTRIES) or none of the outputs associated with the same address. This helps reduce privacy leaks resulting from address reuse. Dust outputs are not eligible to be added to output groups and thus not considered.
m_change_fee Cost of creating the change output.
m_cost_of_change Cost of creating the change output + cost of spending the change output in the future.
m_discard_feerate If the cost to spend a change output at the discard feerate exceeds its value, drop it to fees.
m_effective_feerate The targeted feerate of the transaction being built.
m_include_unsafe_inputs When true, allow unsafe coins to be selected during Coin Selection. This may spend unconfirmed outputs: 1) Received from other wallets, 2) replacing other txs, 3) that have been replaced.
m_long_term_feerate The feerate estimate used to estimate an upper bound on what should be sufficient to spend the change output sometime in the future.
m_max_tx_weight The maximum weight for this transaction.
m_min_change_target Mininmum change to target in Knapsack solver and CoinGrinder: select coins to cover the payment and at least this value of change.
m_subtract_fee_outputs Indicate that we are subtracting the fee from outputs
m_version The version of the transaction we are trying to create.
min_viable_change Minimum amount for creating a change output. If change budget is smaller than min_change then we forgo creation of change output.
rng_fast Randomness to use in the context of coin selection.
tx_noinputs_size Size of the transaction before coin selection, consisting of the header and recipient output(s), excluding the inputs and change output(s).