Documentation ¶
Index ¶
- Variables
- func Add(db sql.Executor, block *types.Block) error
- func ContextualValidity(db sql.Executor, lid types.LayerID) ([]types.BlockContextualValidity, error)
- func Get(db sql.Executor, id types.BlockID) (rst *types.Block, err error)
- func GetBlobSizes(db sql.Executor, ids [][]byte) (sizes []int, err error)
- func GetLayer(db sql.Executor, id types.BlockID) (types.LayerID, error)
- func Has(db sql.Executor, id types.BlockID) (bool, error)
- func IDsInLayer(db sql.Executor, lid types.LayerID) ([]types.BlockID, error)
- func IsValid(db sql.Executor, id types.BlockID) (rst bool, err error)
- func LastValid(db sql.Executor) (types.LayerID, error)
- func Layer(db sql.Executor, lid types.LayerID) ([]*types.Block, error)
- func LoadBlob(ctx context.Context, db sql.Executor, id []byte, b *sql.Blob) error
- func SetInvalid(db sql.Executor, id types.BlockID) error
- func SetValid(db sql.Executor, id types.BlockID) error
- func UpdateValid(db sql.Executor, id types.BlockID, valid bool) error
Constants ¶
This section is empty.
Variables ¶
View Source
var ErrValidityNotDecided = errors.New("block validity undecided")
Functions ¶
func ContextualValidity ¶
func ContextualValidity(db sql.Executor, lid types.LayerID) ([]types.BlockContextualValidity, error)
ContextualValidity returns tuples with block id and contextual validity for all blocks in the layer.
func GetBlobSizes ¶ added in v1.4.1
GetBlobSizes returns the sizes of the blobs corresponding to blocks with specified ids. For non-existent ballots, the corresponding items are set to -1.
func IDsInLayer ¶
IDsInLayer returns list of block ids in the layer.
func LoadBlob ¶ added in v1.4.1
LoadBlob loads block as an encoded blob, ready to be sent over the wire.
func SetInvalid ¶
SetInvalid updates blocks to an invalid status.
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.