types

package
v0.0.1 Latest Latest
Warning

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

Go to latest
Published: Jul 27, 2023 License: Apache-2.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

View Source
const (
	Transport = "tcp"
)

Variables

View Source
var (
	ErrorNilRequest       = errors.New("request cannot be nil")
	ErrorProviderNotFound = errors.New("provider not found")
	ErrorOracleNotRunning = errors.New("oracle is not running")
	ErrorContextCancelled = errors.New("context cancelled")
)

Client sentinel errors.

Functions

func ToReqPrices

func ToReqPrices(prices map[types.CurrencyPair]*uint256.Int) map[string]string

Types

type Oracle

type Oracle interface {
	IsRunning() bool
	GetLastSyncTime() time.Time
	GetPrices() map[types.CurrencyPair]*uint256.Int
	Start(ctx context.Context) error
	Stop()
}

Oracle is interface the OracleServer expects its underlying oracle to implement

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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