gf_eth_contract

package
v0.0.0-...-225a141 Latest Latest
Warning

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

Go to latest
Published: May 25, 2022 License: GPL-2.0 Imports: 13 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Enrich

func Enrich(p_gf_abi *GF_eth__abi,
	p_ctx context.Context,
	p_metrics *gf_eth_core.GF_metrics,
	p_runtime *gf_eth_core.GF_runtime) *gf_core.GF_error

-------------------------------------------------

func Eth_abi__get

func Eth_abi__get(p_gf_abi *GF_eth__abi,
	p_ctx context.Context,
	p_metrics *gf_eth_core.GF_metrics,
	p_runtime *gf_eth_core.GF_runtime) (*abi.ABI, *gf_core.GF_error)

-------------------------------------------------

func Eth_abi__get_defs

func Eth_abi__get_defs(p_ctx context.Context,
	p_metrics *gf_eth_core.GF_metrics,
	p_runtime *gf_eth_core.GF_runtime) (map[string]*GF_eth__abi, *gf_core.GF_error)

-------------------------------------------------

func Eth_opscodes__get_tables

func Eth_opscodes__get_tables() map[string]map[string]gf_eth_opcode

-------------------------------------------------

func Get_code

func Get_code(p_contract_addr_str string,
	p_block_num_int uint64,
	p_ctx context.Context,
	p_eth_rpc_client *ethclient.Client,
	p_runtime_sys *gf_core.Runtime_sys) ([]byte, *gf_core.GF_error)

-------------------------------------------------

func Is_type_valid

func Is_type_valid(p_type_str string) bool

-------------------------------------------------

func Py__run_plugin__get_contract_info

func Py__run_plugin__get_contract_info(p_new_contract_addr_str string,
	p_plugins_info *gf_eth_core.GF_py_plugins,
	p_runtime_sys *gf_core.Runtime_sys) *gf_core.GF_error

-------------------------------------------------

Types

type GF_eth__abi

type GF_eth__abi struct {
	Type_str string                   `bson:"type_str"`
	Def_lst  []map[string]interface{} `bson:"def_lst"`
}

-------------------------------------------------

func Eth_abi__db__get

func Eth_abi__db__get(p_abi_type_str string,
	p_ctx context.Context,
	p_metrics *gf_eth_core.GF_metrics,
	p_runtime *gf_eth_core.GF_runtime) ([]*GF_eth__abi, *gf_core.GF_error)

-------------------------------------------------

type GF_eth__contract_new

type GF_eth__contract_new struct {
	Addr_str       string `json:"addr_str"`
	Code_bytes_lst []byte `json:"-"` // in json serialization []byte is not included, just the base64 encoding
	Code_hex_str   string `json:"code_hex_str"`
	// Code_b64_str   string `json:"code_b64_str"`
	Block_num_int uint64 `json:"block_num_int"`
}

-------------------------------------------------

func Get_via_rpc

func Get_via_rpc(p_contract_addr_str string,
	p_block_num_int uint64,
	p_ctx context.Context,
	p_eth_rpc_client *ethclient.Client,
	p_runtime_sys *gf_core.Runtime_sys) (*GF_eth__contract_new, *gf_core.GF_error)

-------------------------------------------------

type GF_eth__opcode

type GF_eth__opcode struct {
	Op_and_args_str string
	Addr_hex_str    string
}

-------------------------------------------------

func Eth_contract__get_opcodes

func Eth_contract__get_opcodes(p_bytecode_hex_str string,
	p_runtime *gf_eth_core.GF_runtime) ([]*GF_eth__opcode, *gf_core.GF_error)

-------------------------------------------------

Jump to

Keyboard shortcuts

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