Documentation
¶
Index ¶
- type FakeEC
- func (ec *FakeEC) Finalize(context.Context, gpbft.TipSetKey) error
- func (ec *FakeEC) GetCurrentHead() int64
- func (ec *FakeEC) GetHead(ctx context.Context) (ec.TipSet, error)
- func (ec *FakeEC) GetParent(ctx context.Context, ts ec.TipSet) (ec.TipSet, error)
- func (ec *FakeEC) GetPowerTable(ctx context.Context, tsk gpbft.TipSetKey) (gpbft.PowerEntries, error)
- func (ec *FakeEC) GetTipset(_ context.Context, tsk gpbft.TipSetKey) (ec.TipSet, error)
- func (ec *FakeEC) GetTipsetByEpoch(ctx context.Context, epoch int64) (ec.TipSet, error)
- func (ec *FakeEC) Pause()
- func (ec *FakeEC) Resume()
- type FakeECOption
- func WithBootstrapEpoch(epoch int64) FakeECOption
- func WithECPeriod(ecPeriod time.Duration) FakeECOption
- func WithEvolvingPowerTable(fn PowerTableMutator) FakeECOption
- func WithInitialPowerTable(initialPowerTable gpbft.PowerEntries) FakeECOption
- func WithMaxLookback(distance int64) FakeECOption
- func WithSeed(seed uint64) FakeECOption
- type PowerTableMutator
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type FakeEC ¶
type FakeEC struct {
// contains filtered or unexported fields
}
func (*FakeEC) GetCurrentHead ¶
func (*FakeEC) GetPowerTable ¶
func (*FakeEC) GetTipsetByEpoch ¶
GetTipsetByHeight should return a tipset or nil/empty byte array if it does not exists
type FakeECOption ¶
type FakeECOption func(*fakeECConfig)
func WithBootstrapEpoch ¶
func WithBootstrapEpoch(epoch int64) FakeECOption
func WithECPeriod ¶
func WithECPeriod(ecPeriod time.Duration) FakeECOption
func WithEvolvingPowerTable ¶
func WithEvolvingPowerTable(fn PowerTableMutator) FakeECOption
func WithInitialPowerTable ¶
func WithInitialPowerTable(initialPowerTable gpbft.PowerEntries) FakeECOption
func WithMaxLookback ¶
func WithMaxLookback(distance int64) FakeECOption
func WithSeed ¶
func WithSeed(seed uint64) FakeECOption
type PowerTableMutator ¶
type PowerTableMutator func(epoch int64, pt gpbft.PowerEntries) gpbft.PowerEntries
Click to show internal directories.
Click to hide internal directories.