Documentation ¶
Overview ¶
Package abiutil contains helpers for parsing contract metadata
Index ¶
- func GetSelectorByName(name string, metadata *bind.MetaData) ([4]byte, error)
- func GetStringSelectorByName(name string, metadata *bind.MetaData) (string, error)
- func MustGetSelectorByName(name string, metadata *bind.MetaData) [4]byte
- func UnpackInputData(input []byte, metadata *bind.MetaData) ([]interface{}, error)
- func UnpackInputDataToInterface(v interface{}, input []byte, metadata *bind.MetaData) error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func GetSelectorByName ¶
GetSelectorByName takes a function name and a pointer to a `bind.MetaData` object, searches for the first function testContract in the `Sigs` map of the metadata object that matches the function name, and returns the first four bytes of the keccak256 hash of the function testContract as a `[4]byte` array.
func GetStringSelectorByName ¶
GetStringSelectorByName takes a function name and a pointer to a `bind.MetaData` object, searches for the first function testContract in the `Sigs` map of the metadata object that matches the function name, and returns the first four bytes of the keccak256 hash of the function testContract as a string.
func MustGetSelectorByName ¶
MustGetSelectorByName is a wrapper around `GetSelectorByName` that panics if an error is returned.
func UnpackInputData ¶
UnpackInputData takes a function name and a pointer to a `bind.MetaData` object,.
Types ¶
This section is empty.