Versions in this module Expand all Collapse all v1 v1.0.0 Jun 11, 2019 Changes in this version + const DefaultBlockPrioritySize + const DefaultEstimateFeeMaxRollback + const DefaultEstimateFeeMinRegisteredBlocks + const DefaultMinRelayTxFee + var EstimateFeeDatabaseKey = []byte("estimatefee") + func DisableLog() + func ErrToRejectErr(err error) (wire.RejectCode, string) + func UseLogger(logger bsvlog.Logger) + type BsvPerKilobyte float64 + type Config struct + AddrIndex *indexers.AddrIndex + BestHeight func() int32 + CalcSequenceLock func(*bsvutil.Tx, *blockchain.UtxoViewpoint) (*blockchain.SequenceLock, error) + ChainParams *chaincfg.Params + FeeEstimator *FeeEstimator + FetchUtxoView func(*bsvutil.Tx) (*blockchain.UtxoViewpoint, error) + HashCache *txscript.HashCache + IsDeploymentActive func(deploymentID uint32) (bool, error) + MedianTimePast func() time.Time + Policy Policy + SigCache *txscript.SigCache + type FeeEstimator struct + func NewFeeEstimator(maxRollback, minRegisteredBlocks uint32) *FeeEstimator + func RestoreFeeEstimator(data FeeEstimatorState) (*FeeEstimator, error) + func (ef *FeeEstimator) EstimateFee(numBlocks uint32) (BsvPerKilobyte, error) + func (ef *FeeEstimator) LastKnownHeight() int32 + func (ef *FeeEstimator) ObserveTransaction(t *TxDesc) + func (ef *FeeEstimator) RegisterBlock(block *bsvutil.Block) error + func (ef *FeeEstimator) Rollback(hash *chainhash.Hash) error + func (ef *FeeEstimator) Save() FeeEstimatorState + type FeeEstimatorState []byte + type Policy struct + AcceptNonStd bool + DisableRelayPriority bool + FreeTxRelayLimit float64 + MaxOrphanTxSize int + MaxOrphanTxs int + MaxSigOpPerTx int + MaxTxVersion int32 + MinRelayTxFee bsvutil.Amount + type RuleError struct + Err error + func (e RuleError) Error() string + type SatoshiPerByte float64 + func NewSatoshiPerByte(fee bsvutil.Amount, size uint32) SatoshiPerByte + func (rate SatoshiPerByte) Fee(size uint32) bsvutil.Amount + func (rate SatoshiPerByte) ToBsvPerKb() BsvPerKilobyte + type Tag uint64 + type TxDesc struct + StartingPriority float64 + type TxPool struct + func New(cfg *Config) *TxPool + func (mp *TxPool) CheckSpend(op wire.OutPoint) *bsvutil.Tx + func (mp *TxPool) Count() int + func (mp *TxPool) FetchTransaction(txHash *chainhash.Hash) (*bsvutil.Tx, error) + func (mp *TxPool) HaveTransaction(hash *chainhash.Hash) bool + func (mp *TxPool) IsOrphanInPool(hash *chainhash.Hash) bool + func (mp *TxPool) IsTransactionInPool(hash *chainhash.Hash) bool + func (mp *TxPool) LastUpdated() time.Time + func (mp *TxPool) MaybeAcceptTransaction(tx *bsvutil.Tx, isNew, rateLimit bool) ([]*chainhash.Hash, *TxDesc, error) + func (mp *TxPool) MiningDescs() []*mining.TxDesc + func (mp *TxPool) ProcessOrphans(acceptedTx *bsvutil.Tx) []*TxDesc + func (mp *TxPool) ProcessTransaction(tx *bsvutil.Tx, allowOrphan, rateLimit bool, tag Tag) ([]*TxDesc, error) + func (mp *TxPool) RawMempoolVerbose() map[string]*btcjson.GetRawMempoolVerboseResult + func (mp *TxPool) RemoveDoubleSpends(tx *bsvutil.Tx) + func (mp *TxPool) RemoveOrphan(tx *bsvutil.Tx) + func (mp *TxPool) RemoveOrphansByTag(tag Tag) uint64 + func (mp *TxPool) RemoveTransaction(tx *bsvutil.Tx, removeRedeemers bool) + func (mp *TxPool) TxDescs() []*TxDesc + func (mp *TxPool) TxHashes() []*chainhash.Hash + type TxRuleError struct + Description string + RejectCode wire.RejectCode + func (e TxRuleError) Error() string