sync_internal

package
v0.11.0 Latest Latest
Warning

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

Go to latest
Published: Mar 24, 2026 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var NoSignaturesExpectedErr = proto.NewInfoMsg(errors.New("no signatures expected"))
View Source
var UnexpectedBlockErr = proto.NewInfoMsg(errors.New("unexpected block"))

Functions

This section is empty.

Types

type BlockApplied

type BlockApplied bool

type Blocks

type Blocks []*proto.Block

type Eof

type Eof = bool

type Internal

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

func InternalFromLastSignatures

func InternalFromLastSignatures(
	p extension.PeerExtension,
	signatures *signatures.ReverseOrdering,
	isLightNode bool,
) Internal

func NewInternal

func NewInternal(
	orderedBlocks *ordered_blocks.OrderedBlocks,
	respondedSignatures *signatures.ReverseOrdering,
	waitingForSignatures bool,
	isLightNode bool,
) Internal

func (Internal) AskBlocksIDs

func (a Internal) AskBlocksIDs(p peerExtension)

func (Internal) AvailableCount

func (a Internal) AvailableCount() int

func (Internal) Block

func (a Internal) Block(block *proto.Block) (Internal, error)

func (Internal) BlockIDs

func (a Internal) BlockIDs(p PeerExtension, ids []proto.BlockID) (Internal, error)

func (Internal) Blocks

func (a Internal) Blocks() (Internal, Blocks, Snapshots, Eof)

func (Internal) RequestedCount

func (a Internal) RequestedCount() int

func (Internal) SetSnapshot

func (a Internal) SetSnapshot(blockID proto.BlockID, snapshot *proto.BlockSnapshot) (Internal, error)

func (Internal) WaitingForSignatures

func (a Internal) WaitingForSignatures() bool

type PeerExtension

type PeerExtension interface {
	AskBlocksIDs(id []proto.BlockID)
	AskBlock(id proto.BlockID)
	AskBlockSnapshot(id proto.BlockID)
}

type Snapshots

type Snapshots []*proto.BlockSnapshot

Jump to

Keyboard shortcuts

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