12 #include "validation.h"
25 if (nFeeNeeded == 0) {
26 int estimateFoundTarget = (int) nConfirmTarget;
27 nFeeNeeded = pool.
estimateSmartFee((
int) nConfirmTarget, &estimateFoundTarget).GetFee(nTxBytes);
30 if (nFeeNeeded == 0 || (
unsigned int) estimateFoundTarget > nConfirmTarget)
int64_t CAmount
Amount in PIV (Can be negative)
CAmount GetFee(size_t size) const
CTxMemPool stores valid-according-to-the-current-best-chain transactions that may be included in the ...
CFeeRate estimateSmartFee(int nBlocks, int *answerFoundAtBlocks=nullptr) const
Estimate fee rate needed to get into the next nBlocks If no answer can be given at nBlocks,...
static CFeeRate minTxFee
Fees smaller than this (in upiv) are considered zero fee (for transaction creation) We are ~100 times...
CFeeRate minRelayTxFee
Fees smaller than this (in upiv) are considered zero fee (for relaying, mining and transaction creati...
CAmount GetMinimumFee(unsigned int nTxBytes, unsigned int nConfirmTarget, const CTxMemPool &pool)
Estimate the minimum fee considering user set parameters and the required fee.
CAmount GetRequiredFee(unsigned int nTxBytes)
Return the minimum required fee taking into account the floating relay fee and user set minimum trans...
CFeeRate payTxFee(DEFAULT_TRANSACTION_FEE)
Settings.