precompilebind

package
v0.6.3-rc.1 Latest Latest
Warning

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

Go to latest
Published: May 19, 2024 License: GPL-3.0, LGPL-3.0 Imports: 6 Imported by: 0

Documentation

Overview

Package bind generates Ethereum contract Go bindings.

Detailed usage document and tutorial available on the go-ethereum Wiki page: https://github.com/ethereum/go-ethereum/wiki/Native-DApps:-Go-bindings-to-Ethereum-contracts

(c) 2019-2022, Ava Labs, Inc. All rights reserved. See the file LICENSE for licensing terms.

(c) 2019-2022, Ava Labs, Inc. All rights reserved. See the file LICENSE for licensing terms.

(c) 2019-2022, Ava Labs, Inc. All rights reserved. See the file LICENSE for licensing terms.

(c) 2019-2022, Ava Labs, Inc. All rights reserved. See the file LICENSE for licensing terms.

(c) 2019-2023, Ava Labs, Inc. All rights reserved. See the file LICENSE for licensing terms.

(c) 2019-2022, Ava Labs, Inc. All rights reserved. See the file LICENSE for licensing terms.

Index

Constants

View Source
const (
	ContractFileName     = "contract.go"
	ConfigFileName       = "config.go"
	ModuleFileName       = "module.go"
	EventFileName        = "event.go"
	ContractTestFileName = "contract_test.go"
	ConfigTestFileName   = "config_test.go"
)

Variables

This section is empty.

Functions

This section is empty.

Types

type PrecompileBindFile

type PrecompileBindFile struct {
	// FileName is the name of the file to be generated.
	FileName string
	// Content is the content of the file to be generated.
	Content string
	// IsTest indicates whether the file is a test file.
	IsTest bool
}

func NewPrecompileBindFile

func NewPrecompileBindFile(fileName string, content string, isTest bool) PrecompileBindFile

func PrecompileBind

func PrecompileBind(types []string, abiData string, bytecodes []string, fsigs []map[string]string, pkg string, lang bind.Lang, libs map[string]string, aliases map[string]string, abifilename string, generateTests bool) ([]PrecompileBindFile, error)

PrecompileBind generates a Go binding for a precompiled contract. It returns a slice of PrecompileBindFile structs containing the file name and its contents.

Jump to

Keyboard shortcuts

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