37 return std::make_optional(ext_it->second);
bool GetBoolArg(const std::string &strArg, bool fDefault) const
Return boolean argument or default value.
An outpoint - a combination of a transaction hash and an index n into its vout.
An output of a transaction.
bool HasInputWeight(const COutPoint &outpoint) const
Returns true if the input weight is set.
std::optional< CTxOut > GetExternalOutput(const COutPoint &outpoint) const
Returns the external output for the given outpoint if it exists.
int64_t GetInputWeight(const COutPoint &outpoint) const
Returns the input weight.
void Select(const COutPoint &output)
Lock-in the given output for spending.
void SelectExternal(const COutPoint &outpoint, const CTxOut &txout)
Lock-in the given output as an external input for spending because it is not in the wallet.
std::map< COutPoint, CTxOut > m_external_txouts
Map of external inputs to include in the transaction These are not in the wallet, so we need to track...
bool IsSelected(const COutPoint &output) const
Returns true if the given output is pre-selected.
std::set< COutPoint > m_selected_inputs
Selected inputs (inputs that will be used, regardless of whether they're optimal or not)
void UnSelectAll()
Unselects all outputs.
std::map< COutPoint, int64_t > m_input_weights
Map of COutPoints to the maximum weight for that input.
bool HasSelected() const
Returns true if there are pre-selected inputs.
void SetInputWeight(const COutPoint &outpoint, int64_t weight)
Set an input's weight.
bool m_avoid_partial_spends
Avoid partial use of funds sent to a given address.
bool IsExternalSelected(const COutPoint &output) const
Returns true if the given output is selected as an external input.
std::vector< COutPoint > ListSelected() const
List the selected inputs.
void UnSelect(const COutPoint &output)
Unselects the given output.
static constexpr bool DEFAULT_AVOIDPARTIALSPENDS
Default for -avoidpartialspends.