github.com/lbryio/lbcd@v0.22.119/claimtrie/block/repo.go (about)

     1  package block
     2  
     3  import (
     4  	"github.com/lbryio/lbcd/chaincfg/chainhash"
     5  )
     6  
     7  // Repo defines APIs for Block to access persistence layer.
     8  type Repo interface {
     9  	Load() (int32, error)
    10  	Set(height int32, hash *chainhash.Hash) error
    11  	Get(height int32) (*chainhash.Hash, error)
    12  	Close() error
    13  	Flush() error
    14  	Delete(heightMin, heightMax int32) error
    15  }