cosmostxcollector

package
v29.0.0-...-a2903dc Latest Latest
Warning

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

Go to latest
Published: Apr 29, 2024 License: Apache-2.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 Collector

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

Collector defines a type to collect and save Cosmos transactions in a data backend.

func New

func New(db adapter.Saver, client TXsCollector) Collector

New creates a new Cosmos transaction collector.

func (Collector) Collect

func (c Collector) Collect(ctx context.Context, fromHeight int64) error

Collect gathers transactions for all blocks starting from a specific height. Each group of block transactions is saved sequentially after being collected.

type TXsCollector

type TXsCollector interface {
	CollectTXs(ctx context.Context, fromHeight int64, tc chan<- []cosmosclient.TX) error
}

TXsCollector defines the interface for Cosmos clients that support collection of transactions.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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