result

package
v1.7.8 Latest Latest
Warning

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

Go to latest
Published: Nov 28, 2024 License: MIT Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Beacon

type Beacon struct {
	Epoch  types.EpochID
	Beacon types.Beacon
}

type Block

type Block struct {
	Header  types.Vote `json:"header"`
	Valid   bool       `json:"v"`
	Local   bool       `json:"l"` // set to true if block crossed local threshold
	Invalid bool       `json:"i"`
	Hare    bool       `json:"h"`
	Data    bool       `json:"d"`
}

func (*Block) MarshalLogObject

func (b *Block) MarshalLogObject(encoder zapcore.ObjectEncoder) error

type Layer

type Layer struct {
	Layer    types.LayerID `json:"lid"`
	Verified bool          `json:"v"`
	Opinion  types.Hash32  `json:"opinion"`
	Blocks   []Block       `json:"blocks"`
}

func (*Layer) FirstValid

func (l *Layer) FirstValid() types.BlockID

FirstValid returns first block that crossed positive tortoise threshold, or if layer didn't accumulate enough weight yet - use hare result.

func (*Layer) MarshalLogObject

func (l *Layer) MarshalLogObject(encoder zapcore.ObjectEncoder) error

func (Layer) String

func (l Layer) String() string

Jump to

Keyboard shortcuts

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