Versions in this module Expand all Collapse all v0 v0.5.6 Jul 16, 2024 v0.0.1 Jun 28, 2024 Changes in this version + var DefaultConfig = Config + var ErrAlreadyKnown = errors.New("already known") + var ErrFutureReplacePending = errors.New("future transaction tries to replace pending") + var ErrGasLimit = errors.New("exceeds block gas limit") + var ErrInvalidSender = errors.New("invalid sender") + var ErrNegativeValue = errors.New("negative value") + var ErrOverdraft = errors.New("transaction would cause overdraft") + var ErrOversizedData = errors.New("oversized data") + var ErrReplaceUnderpriced = errors.New("replacement transaction underpriced") + var ErrTxPoolOverflow = errors.New("txpool is full") + var ErrUnderpriced = errors.New("transaction underpriced") + type Config struct + AccountQueue uint64 + AccountSlots uint64 + GlobalQueue uint64 + GlobalSlots uint64 + Journal string + Lifetime time.Duration + Locals []common.Address + NoLocals bool + PriceBump uint64 + PriceLimit uint64 + Rejournal time.Duration + type TxPool struct + func NewTxPool(config Config, chainconfig *params.ChainConfig, chain blockChain) *TxPool + func (pool *TxPool) AddLocal(tx *types.Transaction) error + func (pool *TxPool) AddLocals(txs []*types.Transaction) []error + func (pool *TxPool) AddRemote(tx *types.Transaction) error + func (pool *TxPool) AddRemotes(txs []*types.Transaction) []error + func (pool *TxPool) AddRemotesSync(txs []*types.Transaction) []error + func (pool *TxPool) Content() (map[common.Address]types.Transactions, map[common.Address]types.Transactions) + func (pool *TxPool) ContentFrom(addr common.Address) (types.Transactions, types.Transactions) + func (pool *TxPool) GasPrice() *big.Int + func (pool *TxPool) Get(hash common.Hash) *types.Transaction + func (pool *TxPool) Has(hash common.Hash) bool + func (pool *TxPool) HasLocal(hash common.Hash) bool + func (pool *TxPool) IteratePending(f func(tx *types.Transaction) bool) + func (pool *TxPool) Locals() []common.Address + func (pool *TxPool) Nonce(addr common.Address) uint64 + func (pool *TxPool) Pending(enforceTips bool) map[common.Address]types.Transactions + func (pool *TxPool) PendingFrom(addrs []common.Address, enforceTips bool) map[common.Address]types.Transactions + func (pool *TxPool) PendingSize() int + func (pool *TxPool) RemoveTx(hash common.Hash) + func (pool *TxPool) SetGasPrice(price *big.Int) + func (pool *TxPool) SetMinFee(minFee *big.Int) + func (pool *TxPool) Stats() (int, int) + func (pool *TxPool) Status(hashes []common.Hash) []TxStatus + func (pool *TxPool) Stop() + func (pool *TxPool) SubscribeNewHeadEvent(ch chan<- core.NewTxPoolHeadEvent) event.Subscription + func (pool *TxPool) SubscribeNewReorgEvent(ch chan<- core.NewTxPoolReorgEvent) event.Subscription + func (pool *TxPool) SubscribeNewTxsEvent(ch chan<- core.NewTxsEvent) event.Subscription + type TxStatus uint + const TxStatusPending + const TxStatusQueued + const TxStatusUnknown