headers

package
v0.0.0-...-c04c664 Latest Latest
Warning

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

Go to latest
Published: Sep 5, 2020 License: MIT Imports: 19 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Bus

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

func NewBus

func NewBus(headers *Headers) *Bus

func (*Bus) GetBtc

func (b *Bus) GetBtc(hash uint32) *wire.BlockHeader

func (*Bus) GetMnt

func (b *Bus) GetMnt(hash string) *types.SignedHeader

type Headers

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

func NewHeaders

func NewHeaders(stateBus *bus.Bus, iavl tree.Tree) (*Headers, error)

func (*Headers) CheckBtc

func (h *Headers) CheckBtc(header wire.BlockHeader, height uint32, network string) error

func (*Headers) CheckMnt

func (h *Headers) CheckMnt(header *tmtypes.SignedHeader, vals *tmtypes.ValidatorSet) error

func (*Headers) Commit

func (h *Headers) Commit() error

func (*Headers) ExistsBtc

func (h *Headers) ExistsBtc(blockHeight uint32) bool

func (*Headers) ExistsMnt

func (h *Headers) ExistsMnt(blockHash string) bool

func (*Headers) Export

func (h *Headers) Export(state *types.AppState)

func (*Headers) GetBtcHeader

func (h *Headers) GetBtcHeader(blockHeight uint32) *wire.BlockHeader

func (*Headers) GetLastBtc

func (h *Headers) GetLastBtc() *chainhash.Hash

func (*Headers) GetMntHeader

func (h *Headers) GetMntHeader(blockHash string) *tmtypes.SignedHeader

func (*Headers) InsertBtc

func (h *Headers) InsertBtc(header wire.BlockHeader, height uint32)

func (*Headers) InsertMnt

func (h *Headers) InsertMnt(header tmtypes.SignedHeader)

Jump to

Keyboard shortcuts

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