common

package
v1.0.0 Latest Latest
Warning

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

Go to latest
Published: Aug 30, 2023 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func SliceToAddresses

func SliceToAddresses(slice []string) []common.Address

SliceToAddresses ... Converts a slice of strings to a slice of addresses

func WeiToEther

func WeiToEther(wei *big.Int) *big.Float

WeiToEther ... Converts wei to ether

Types

type DLQ added in v1.0.0

type DLQ[E any] struct {
	// contains filtered or unexported fields
}

DLQ ... Dead Letter Queue construct Used to store ETL events that failed to be processed

func NewTransitDLQ added in v1.0.0

func NewTransitDLQ(size int) *DLQ[core.TransitData]

NewTransitDLQ ... Initializer

func (*DLQ[E]) Add added in v1.0.0

func (d *DLQ[E]) Add(entry *E) error

Add ... Adds an entry to the DLQ if it is not full

func (*DLQ[E]) Empty added in v1.0.0

func (d *DLQ[E]) Empty() bool

Empty ... Checks if the DLQ is empty

func (*DLQ[E]) Pop added in v1.0.0

func (d *DLQ[E]) Pop() (*E, error)

Pop ... Removes the first element from the DLQ, typically for re-processing

func (*DLQ[E]) PopAll added in v1.0.0

func (d *DLQ[E]) PopAll() []*E

PopAll ... Removes all elements from the DLQ, typically for re-processing

func (*DLQ[E]) Size added in v1.0.0

func (d *DLQ[E]) Size() int

Size ... Returns the size of the DLQ

Jump to

Keyboard shortcuts

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