Versions in this module Expand all Collapse all v1 v1.0.0 Jan 21, 2020 Changes in this version + const BlockHeaderSize + const MedianTimeBlocks + const RegularFilterHeaderSize + var ErrHashNotFound = fmt.Errorf("target hash not found in index") + var ErrHeightNotFound = fmt.Errorf("target height not found in index") + type BlockHeader struct + Height uint32 + type BlockHeaderStore interface + CalcPastMedianTime func([]*wire.BlockHeader) (time.Time, error) + ChainTip func() (*wire.BlockHeader, uint32, error) + FetchHeader func(*chainhash.Hash) (*wire.BlockHeader, uint32, error) + FetchHeaderAncestors func(uint32, *chainhash.Hash) ([]wire.BlockHeader, uint32, error) + FetchHeaderByHeight func(height uint32) (*wire.BlockHeader, error) + HeightFromHash func(*chainhash.Hash) (uint32, error) + LatestBlockLocator func() (blockchain.BlockLocator, error) + RollbackLastBlock func() (*waddrmgr.BlockStamp, error) + WriteHeaders func(...BlockHeader) error + func NewBlockHeaderStore(filePath string, db walletdb.DB, netParams *chaincfg.Params) (BlockHeaderStore, error) + type ErrHeaderNotFound struct + type FilterHeader struct + FilterHash chainhash.Hash + HeaderHash chainhash.Hash + Height uint32 + type FilterHeaderStore struct + func NewFilterHeaderStore(filePath string, db walletdb.DB, filterType HeaderType, ...) (*FilterHeaderStore, error) + func (f *FilterHeaderStore) ChainTip() (*chainhash.Hash, uint32, error) + func (f *FilterHeaderStore) FetchHeader(hash *chainhash.Hash) (*chainhash.Hash, error) + func (f *FilterHeaderStore) FetchHeaderAncestors(numHeaders uint32, stopHash *chainhash.Hash) ([]chainhash.Hash, uint32, error) + func (f *FilterHeaderStore) FetchHeaderByHeight(height uint32) (*chainhash.Hash, error) + func (f *FilterHeaderStore) RollbackLastBlock(newTip *chainhash.Hash) (*waddrmgr.BlockStamp, error) + func (f *FilterHeaderStore) WriteHeaders(hdrs ...FilterHeader) error + type HeaderType uint8 + const Block + const RegularFilter