embeds

package
v2.0.0-evm.7 Latest Latest
Warning

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

Go to latest
Published: Aug 16, 2024 License: Apache-2.0 Imports: 4 Imported by: 0

README

Nibiru Contract Embeds

npm install
npx hardhat compile

Documentation

Overview

Package "embeds" adds access to files (smart contracts) embedded in the Go runtime. Go source files that import "embed" can use the //go:embed directive to initialize a variable of type string, \[]byte, or \[FS] with the contents of files read from the package directory or subdirectories at compile time.

Index

Constants

This section is empty.

Variables

View Source
var (
	// Contract_ERC20Minter: The default ERC20 contract deployed during the
	// creation of a `FunToken` mapping from a bank coin.
	SmartContract_ERC20Minter = CompiledEvmContract{
		Name:      "ERC20Minter.sol",
		EmbedJSON: erc20MinterContractJSON,
	}

	// SmartContract_Funtoken: Precompile contract interface for
	// "IFunToken.sol". This precompile enables transfers of ERC20 tokens
	// to non-EVM accounts. Only the ABI is used.
	SmartContract_FunToken = CompiledEvmContract{
		Name:      "FunToken.sol",
		EmbedJSON: funtokenContractJSON,
	}

	SmartContract_TestERC20 = CompiledEvmContract{
		Name:      "TestERC20.sol",
		EmbedJSON: testErc20Json,
	}
)

Functions

This section is empty.

Types

type CompiledEvmContract

type CompiledEvmContract struct {
	Name      string
	EmbedJSON []byte

	// filled in post-load
	ABI      *gethabi.ABI `json:"abi"`
	Bytecode []byte       `json:"bytecode"`
}

func (*CompiledEvmContract) MustLoad

func (sc *CompiledEvmContract) MustLoad()

Jump to

Keyboard shortcuts

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