substratehelper

package
v1.4.553 Latest Latest
Warning

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

Go to latest
Published: Oct 31, 2024 License: GPL-2.0 Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type SubstrateEventHelper

type SubstrateEventHelper struct {
	API *gsrpc.SubstrateAPI
	// contains filtered or unexported fields
}

func NewSubstrateEventHelper

func NewSubstrateEventHelper(nodeURL string, logger *logrus.Entry) (*SubstrateEventHelper, error)

func (*SubstrateEventHelper) DecodeEvents

func (s *SubstrateEventHelper) DecodeEvents(blockHash types.Hash) ([]*parser.Event, error)

func (*SubstrateEventHelper) ListenForNewBlocks

func (s *SubstrateEventHelper) ListenForNewBlocks(callback func([]*parser.Event, uint64)) error

ListenForNewBlocks listens for new blocks and continuously decodes events.

func (*SubstrateEventHelper) ListenForSpecificBlock

func (s *SubstrateEventHelper) ListenForSpecificBlock(blockNumber uint64, callback func([]*parser.Event, uint64)) error

Directories

Path Synopsis
gethrpc
Package rpc implements bi-directional JSON-RPC 2.0 on multiple transports.
Package rpc implements bi-directional JSON-RPC 2.0 on multiple transports.
rpc

Jump to

Keyboard shortcuts

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