geth

package
v0.3.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Oct 5, 2021 License: AGPL-3.0 Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var ErrStorageQueryFailed = errors.New("oracle contract storage query failed")

Functions

This section is empty.

Types

type Median

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

Median implements the oracle.Median interface using go-ethereum packages.

func NewMedian

func NewMedian(ethereum ethereum.Client, address ethereum.Address) *Median

NewMedian creates the new Median instance.

func (*Median) Address added in v0.2.0

func (m *Median) Address() common.Address

Address implements the oracle.Median interface.

func (*Median) Age

func (m *Median) Age(ctx context.Context) (time.Time, error)

Age implements the oracle.Median interface.

func (*Median) Bar

func (m *Median) Bar(ctx context.Context) (int64, error)

Bar implements the oracle.Median interface.

func (*Median) Drop

func (m *Median) Drop(ctx context.Context, addresses []common.Address, simulateBeforeRun bool) (*ethereum.Hash, error)

Drop implements the oracle.Median interface.

func (*Median) Feeds

func (m *Median) Feeds(ctx context.Context) ([]ethereum.Address, error)

Feeds implements the oracle.Median interface.

func (*Median) Lift

func (m *Median) Lift(ctx context.Context, addresses []common.Address, simulateBeforeRun bool) (*ethereum.Hash, error)

Lift implements the oracle.Median interface.

func (*Median) Poke

func (m *Median) Poke(ctx context.Context, prices []*oracle.Price, simulateBeforeRun bool) (*ethereum.Hash, error)

Poke implements the oracle.Median interface.

func (*Median) SetBar

func (m *Median) SetBar(ctx context.Context, bar *big.Int, simulateBeforeRun bool) (*ethereum.Hash, error)

SetBar implements the oracle.Median interface.

func (*Median) Val

func (m *Median) Val(ctx context.Context) (*big.Int, error)

Val implements the oracle.Median interface.

func (*Median) Wat

func (m *Median) Wat(ctx context.Context) (string, error)

Wat implements the oracle.Median interface.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL