test

package
v0.22.8 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Oct 5, 2021 License: AGPL-3.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type BlockBuilder

type BlockBuilder struct {
	// contains filtered or unexported fields
}

func NewBlockBuilder

func NewBlockBuilder() *BlockBuilder

func (*BlockBuilder) Add

func (f *BlockBuilder) Add(qcView uint64, blockView uint64)

func (*BlockBuilder) AddVersioned

func (f *BlockBuilder) AddVersioned(qcView uint64, blockView uint64, qcversion int, blockversion int)

[3,4] denotes a block of view 4, with a qc of view 3. [3,4'] denotes a block of view 4, with a qc of view 3, but has a different BlockID than [3,4], [3,4'] can be created by AddVersioned(3, 4, 0, 1) [3',4] can be created by AddVersioned(3, 4, 1, 0)

func (*BlockBuilder) Blocks

func (f *BlockBuilder) Blocks() ([]*model.Block, error)

type BlockView

type BlockView struct {
	View uint64 // the view of the block to be created

	// the version of the block for that view.  useful for creating a different block of the same view with a different version
	BlockVersion int

	QCView uint64 // the view for the QC to be built on top of

	// the version of the QC for that view.
	QCVersion int
}

BlockView specifies the data to create a block

func (*BlockView) BlockIndex

func (bv *BlockView) BlockIndex() string

func (*BlockView) QCIndex

func (bv *BlockView) QCIndex() string

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL