shared

package
v0.0.1 Latest Latest
Warning

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

Go to latest
Published: Oct 13, 2021 License: AGPL-3.0 Imports: 10 Imported by: 28

Documentation

Index

Constants

View Source
const (
	OneTopicRequired    = 1
	TwoTopicsRequired   = 2
	ThreeTopicsRequired = 3
	FourTopicsRequired  = 4
	LogDataRequired     = true
	LogDataNotRequired  = false
)

Variables

View Source
var (
	ErrLogMissingTopics = func(expectedNumTopics, actualNumTopics int) error {
		return fmt.Errorf("log missing topics: has %d, want %d", actualNumTopics, expectedNumTopics)
	}
	ErrLogMissingData   = errors.New("log missing data")
	ErrCouldNotCreateFK = func(err error) error {
		return fmt.Errorf("transformer could not create FK: %v", err)
	}
)

Functions

func BigIntToString

func BigIntToString(value *big.Int) string

func ConvertInt256HexToBigInt

func ConvertInt256HexToBigInt(hex string) *big.Int

func ConvertIntStringToHex

func ConvertIntStringToHex(n string) (string, error)

func ConvertUint256HexToBigInt

func ConvertUint256HexToBigInt(hex string) *big.Int

func DecodeHexToText

func DecodeHexToText(payload string) string

func FormatRollbackError

func FormatRollbackError(field string, err error) error

func GetChecksumAddressString

func GetChecksumAddressString(address string) string

func GetEventTransformerConfig

func GetEventTransformerConfig(transformerLabel, signature string) event.TransformerConfig

GetEventTransformerConfig creates a transformer config by pulling values from configuration environment

func GetFullTableName

func GetFullTableName(schema, table string) string

func VerifyLog

func VerifyLog(log types.Log, expectedNumTopics int, isDataRequired bool) error

Types

This section is empty.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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