go-ethereum: github.com/ethereum/go-ethereum/eth/gasprice Index | Files

package gasprice

import "github.com/ethereum/go-ethereum/eth/gasprice"

Index

Package Files

gasprice.go

type Config Uses

type Config struct {
    Blocks     int
    Percentile int
    Default    *big.Int `toml:",omitempty"`
}

type Oracle Uses

type Oracle struct {
    // contains filtered or unexported fields
}

Oracle recommends gas prices based on the content of recent blocks. Suitable for both light and full clients.

func NewOracle Uses

func NewOracle(backend ethapi.Backend, params Config) *Oracle

NewOracle returns a new oracle.

func (*Oracle) SuggestPrice Uses

func (gpo *Oracle) SuggestPrice(ctx context.Context) (*big.Int, error)

SuggestPrice returns the recommended gas price.

Package gasprice imports 9 packages (graph) and is imported by 305 packages. Updated 2019-09-19. Refresh now. Tools for package owners.