Documentation ¶
Index ¶
Constants ¶
View Source
const ( LpoAvgCount = 5 LpoMinCount = 3 LpoMaxBlocks = 20 LpoSelect = 50 LpoDefaultPrice = 20000000000 )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type GasPriceOracle ¶
type GasPriceOracle struct {
// contains filtered or unexported fields
}
GasPriceOracle recommends gas prices based on the content of recent blocks.
func NewGasPriceOracle ¶
func NewGasPriceOracle(chain *core.BlockChain, db ethdb.Database, evmux *event.TypeMux, params *GpoParams) *GasPriceOracle
NewGasPriceOracle returns a new oracle.
func (*GasPriceOracle) SuggestPrice ¶
func (self *GasPriceOracle) SuggestPrice() *big.Int
SuggestPrice returns the recommended gas price.
type LightPriceOracle ¶
type LightPriceOracle struct {
// contains filtered or unexported fields
}
LightPriceOracle recommends gas prices based on the content of recent blocks. Suitable for both light and full clients.
func NewLightPriceOracle ¶
func NewLightPriceOracle(backend ethapi.Backend) *LightPriceOracle
NewLightPriceOracle returns a new oracle.
func (*LightPriceOracle) SuggestPrice ¶
SuggestPrice returns the recommended gas price.
Click to show internal directories.
Click to hide internal directories.