blockchain

package
v0.0.0-...-0334a0b Latest Latest
Warning

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

Go to latest
Published: Oct 20, 2024 License: MIT Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type BlockchainProcessor

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

func NewBlockchainProcessor

func NewBlockchainProcessor(cfg *config.Config) *BlockchainProcessor

NewBlockchainProcessor initializes BlockchainProcessor with HTTP and WebSocket clients

func (*BlockchainProcessor) CloseClients

func (p *BlockchainProcessor) CloseClients()

CloseClients closes both HTTP and WebSocket clients gracefully

func (*BlockchainProcessor) GetBlockByNumber

func (p *BlockchainProcessor) GetBlockByNumber(ctx context.Context, blockNumber *big.Int) (*types.Block, error)

func (*BlockchainProcessor) ListenNewBlocks

func (p *BlockchainProcessor) ListenNewBlocks(startBlockNumber int) <-chan *types.Block

Jump to

Keyboard shortcuts

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