github.com/palisadeinc/bor@v0.0.0-20230615125219-ab7196213d15/consensus/bor/heimdall.go (about)

     1  package bor
     2  
     3  import (
     4  	"context"
     5  
     6  	"github.com/ethereum/go-ethereum/consensus/bor/clerk"
     7  	"github.com/ethereum/go-ethereum/consensus/bor/heimdall/checkpoint"
     8  	"github.com/ethereum/go-ethereum/consensus/bor/heimdall/span"
     9  )
    10  
    11  //go:generate mockgen -destination=../../tests/bor/mocks/IHeimdallClient.go -package=mocks . IHeimdallClient
    12  type IHeimdallClient interface {
    13  	StateSyncEvents(ctx context.Context, fromID uint64, to int64) ([]*clerk.EventRecordWithTime, error)
    14  	Span(ctx context.Context, spanID uint64) (*span.HeimdallSpan, error)
    15  	FetchCheckpoint(ctx context.Context, number int64) (*checkpoint.Checkpoint, error)
    16  	FetchCheckpointCount(ctx context.Context) (int64, error)
    17  	Close()
    18  }