github.com/onflow/flow-go@v0.35.7-crescendo-preview.23-atree-inlining/storage/cluster_blocks.go (about)

     1  package storage
     2  
     3  import (
     4  	"github.com/onflow/flow-go/model/cluster"
     5  	"github.com/onflow/flow-go/model/flow"
     6  )
     7  
     8  type ClusterBlocks interface {
     9  
    10  	// Store stores the cluster block.
    11  	Store(block *cluster.Block) error
    12  
    13  	// ByID returns the block with the given ID.
    14  	ByID(blockID flow.Identifier) (*cluster.Block, error)
    15  
    16  	// ByHeight returns the block with the given height. Only available for
    17  	// finalized blocks.
    18  	ByHeight(height uint64) (*cluster.Block, error)
    19  }