test_erc20

package
v0.0.108 Latest Latest
Warning

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

Go to latest
Published: Jul 19, 2024 License: GPL-3.0 Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var TestERC20ABI = TestERC20MetaData.ABI

TestERC20ABI is the input ABI used to generate the binding from. Deprecated: Use TestERC20MetaData.ABI instead.

View Source
var TestERC20Bin = TestERC20MetaData.Bin

TestERC20Bin is the compiled bytecode used for deploying new contracts. Deprecated: Use TestERC20MetaData.Bin instead.

View Source
var TestERC20MetaData = &bind.MetaData{
	ABI: "[{\"inputs\":[{\"internalType\":\"string\",\"name\":\"name_\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"symbol_\",\"type\":\"string\"},{\"internalType\":\"uint8\",\"name\":\"decimals_\",\"type\":\"uint8\"},{\"internalType\":\"uint256\",\"name\":\"cap_\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"increasedSupply\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"cap\",\"type\":\"uint256\"}],\"name\":\"ERC20ExceededCap\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"spender\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"allowance\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"needed\",\"type\":\"uint256\"}],\"name\":\"ERC20InsufficientAllowance\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"balance\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"needed\",\"type\":\"uint256\"}],\"name\":\"ERC20InsufficientBalance\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"approver\",\"type\":\"address\"}],\"name\":\"ERC20InvalidApprover\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"cap\",\"type\":\"uint256\"}],\"name\":\"ERC20InvalidCap\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"receiver\",\"type\":\"address\"}],\"name\":\"ERC20InvalidReceiver\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"}],\"name\":\"ERC20InvalidSender\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"spender\",\"type\":\"address\"}],\"name\":\"ERC20InvalidSpender\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"spender\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"Approval\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"Transfer\",\"type\":\"event\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"spender\",\"type\":\"address\"}],\"name\":\"allowance\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"spender\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"approve\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"balanceOf\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"burn\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"cap\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"decimals\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"mint\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"name\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"symbol\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"totalSupply\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"transfer\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"transferFrom\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]",
	Bin: "0x60c06040523480156200001157600080fd5b5060405162000c1638038062000c1683398101604081905262000034916200015b565b808484600362000045838262000277565b50600462000054828262000277565b50505080600003620000805760405163392e1e2760e01b81526000600482015260240160405180910390fd5b6080525060ff1660a05250620003439050565b634e487b7160e01b600052604160045260246000fd5b600082601f830112620000bb57600080fd5b81516001600160401b0380821115620000d857620000d862000093565b604051601f8301601f19908116603f0116810190828211818310171562000103576200010362000093565b81604052838152602092508660208588010111156200012157600080fd5b600091505b8382101562000145578582018301518183018401529082019062000126565b6000602085830101528094505050505092915050565b600080600080608085870312156200017257600080fd5b84516001600160401b03808211156200018a57600080fd5b6200019888838901620000a9565b95506020870151915080821115620001af57600080fd5b50620001be87828801620000a9565b935050604085015160ff81168114620001d657600080fd5b6060959095015193969295505050565b600181811c90821680620001fb57607f821691505b6020821081036200021c57634e487b7160e01b600052602260045260246000fd5b50919050565b601f82111562000272576000816000526020600020601f850160051c810160208610156200024d5750805b601f850160051c820191505b818110156200026e5782815560010162000259565b5050505b505050565b81516001600160401b0381111562000293576200029362000093565b620002ab81620002a48454620001e6565b8462000222565b602080601f831160018114620002e35760008415620002ca5750858301515b600019600386901b1c1916600185901b1785556200026e565b600085815260208120601f198616915b828110156200031457888601518255948401946001909101908401620002f3565b5085821015620003335787850151600019600388901b60f8161c191681555b5050505050600190811b01905550565b60805160a0516108a6620003706000396000610126015260008181610152015261057301526108a66000f3fe608060405234801561001057600080fd5b50600436106100b45760003560e01c806340c10f191161007157806340c10f191461017657806370a082311461018b57806395d89b41146101b45780639dc29fac146101bc578063a9059cbb146101cf578063dd62ed3e146101e257600080fd5b806306fdde03146100b9578063095ea7b3146100d757806318160ddd146100fa57806323b872dd1461010c578063313ce5671461011f578063355274ea14610150575b600080fd5b6100c161021b565b6040516100ce91906106ef565b60405180910390f35b6100ea6100e536600461075a565b6102ad565b60405190151581526020016100ce565b6002545b6040519081526020016100ce565b6100ea61011a366004610784565b6102c7565b60405160ff7f00000000000000000000000000000000000000000000000000000000000000001681526020016100ce565b7f00000000000000000000000000000000000000000000000000000000000000006100fe565b61018961018436600461075a565b6102eb565b005b6100fe6101993660046107c0565b6001600160a01b031660009081526020819052604090205490565b6100c16102f9565b6101896101ca36600461075a565b610308565b6100ea6101dd36600461075a565b610312565b6100fe6101f03660046107e2565b6001600160a01b03918216600090815260016020908152604080832093909416825291909152205490565b60606003805461022a90610815565b80601f016020809104026020016040519081016040528092919081815260200182805461025690610815565b80156102a35780601f10610278576101008083540402835291602001916102a3565b820191906000526020600020905b81548152906001019060200180831161028657829003601f168201915b5050505050905090565b6000336102bb818585610320565b60019150505b92915050565b6000336102d5858285610332565b6102e08585856103b5565b506001949350505050565b6102f58282610414565b5050565b60606004805461022a90610815565b6102f5828261044a565b6000336102bb8185856103b5565b61032d8383836001610480565b505050565b6001600160a01b0383811660009081526001602090815260408083209386168352929052205460001981146103af57818110156103a057604051637dc7a0d960e11b81526001600160a01b038416600482015260248101829052604481018390526064015b60405180910390fd5b6103af84848484036000610480565b50505050565b6001600160a01b0383166103df57604051634b637e8f60e11b815260006004820152602401610397565b6001600160a01b0382166104095760405163ec442f0560e01b815260006004820152602401610397565b61032d838383610555565b6001600160a01b03821661043e5760405163ec442f0560e01b815260006004820152602401610397565b6102f560008383610555565b6001600160a01b03821661047457604051634b637e8f60e11b815260006004820152602401610397565b6102f582600083610555565b6001600160a01b0384166104aa5760405163e602df0560e01b815260006004820152602401610397565b6001600160a01b0383166104d457604051634a1406b160e11b815260006004820152602401610397565b6001600160a01b03808516600090815260016020908152604080832093871683529290522082905580156103af57826001600160a01b0316846001600160a01b03167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b9258460405161054791815260200190565b60405180910390a350505050565b6105608383836105c5565b6001600160a01b03831661032d576002547f000000000000000000000000000000000000000000000000000000000000000090818111156105be5760405163279e7e1560e21b81526004810182905260248101839052604401610397565b5050505050565b6001600160a01b0383166105f05780600260008282546105e5919061084f565b909155506106629050565b6001600160a01b038316600090815260208190526040902054818110156106435760405163391434e360e21b81526001600160a01b03851660048201526024810182905260448101839052606401610397565b6001600160a01b03841660009081526020819052604090209082900390555b6001600160a01b03821661067e5760028054829003905561069d565b6001600160a01b03821660009081526020819052604090208054820190555b816001600160a01b0316836001600160a01b03167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef836040516106e291815260200190565b60405180910390a3505050565b60006020808352835180602085015260005b8181101561071d57858101830151858201604001528201610701565b506000604082860101526040601f19601f8301168501019250505092915050565b80356001600160a01b038116811461075557600080fd5b919050565b6000806040838503121561076d57600080fd5b6107768361073e565b946020939093013593505050565b60008060006060848603121561079957600080fd5b6107a28461073e565b92506107b06020850161073e565b9150604084013590509250925092565b6000602082840312156107d257600080fd5b6107db8261073e565b9392505050565b600080604083850312156107f557600080fd5b6107fe8361073e565b915061080c6020840161073e565b90509250929050565b600181811c9082168061082957607f821691505b60208210810361084957634e487b7160e01b600052602260045260246000fd5b50919050565b808201808211156102c157634e487b7160e01b600052601160045260246000fdfea26469706673582212208e1d855b565971e54667ea873fb785c40e6392b054a9c005f20cf45bb787736464736f6c63430008160033",
}

TestERC20MetaData contains all meta data concerning the TestERC20 contract.

Functions

This section is empty.

Types

type TestERC20

type TestERC20 struct {
	TestERC20Caller     // Read-only binding to the contract
	TestERC20Transactor // Write-only binding to the contract
	TestERC20Filterer   // Log filterer for contract events
}

TestERC20 is an auto generated Go binding around an Ethereum contract.

func DeployTestERC20

func DeployTestERC20(auth *bind.TransactOpts, backend bind.ContractBackend, name_ string, symbol_ string, decimals_ uint8, cap_ *big.Int) (common.Address, *types.Transaction, *TestERC20, error)

DeployTestERC20 deploys a new Ethereum contract, binding an instance of TestERC20 to it.

func NewTestERC20

func NewTestERC20(address common.Address, backend bind.ContractBackend) (*TestERC20, error)

NewTestERC20 creates a new instance of TestERC20, bound to a specific deployed contract.

type TestERC20Approval

type TestERC20Approval struct {
	Owner   common.Address
	Spender common.Address
	Value   *big.Int
	Raw     types.Log // Blockchain specific contextual infos
}

TestERC20Approval represents a Approval event raised by the TestERC20 contract.

type TestERC20ApprovalIterator

type TestERC20ApprovalIterator struct {
	Event *TestERC20Approval // Event containing the contract specifics and raw log
	// contains filtered or unexported fields
}

TestERC20ApprovalIterator is returned from FilterApproval and is used to iterate over the raw logs and unpacked data for Approval events raised by the TestERC20 contract.

func (*TestERC20ApprovalIterator) Close

func (it *TestERC20ApprovalIterator) Close() error

Close terminates the iteration process, releasing any pending underlying resources.

func (*TestERC20ApprovalIterator) Error

func (it *TestERC20ApprovalIterator) Error() error

Error returns any retrieval or parsing error occurred during filtering.

func (*TestERC20ApprovalIterator) Next

func (it *TestERC20ApprovalIterator) Next() bool

Next advances the iterator to the subsequent event, returning whether there are any more events found. In case of a retrieval or parsing error, false is returned and Error() can be queried for the exact failure.

type TestERC20Caller

type TestERC20Caller struct {
	// contains filtered or unexported fields
}

TestERC20Caller is an auto generated read-only Go binding around an Ethereum contract.

func NewTestERC20Caller

func NewTestERC20Caller(address common.Address, caller bind.ContractCaller) (*TestERC20Caller, error)

NewTestERC20Caller creates a new read-only instance of TestERC20, bound to a specific deployed contract.

func (*TestERC20Caller) Allowance

func (_TestERC20 *TestERC20Caller) Allowance(opts *bind.CallOpts, owner common.Address, spender common.Address) (*big.Int, error)

Allowance is a free data retrieval call binding the contract method 0xdd62ed3e.

Solidity: function allowance(address owner, address spender) view returns(uint256)

func (*TestERC20Caller) BalanceOf

func (_TestERC20 *TestERC20Caller) BalanceOf(opts *bind.CallOpts, account common.Address) (*big.Int, error)

BalanceOf is a free data retrieval call binding the contract method 0x70a08231.

Solidity: function balanceOf(address account) view returns(uint256)

func (*TestERC20Caller) Cap

func (_TestERC20 *TestERC20Caller) Cap(opts *bind.CallOpts) (*big.Int, error)

Cap is a free data retrieval call binding the contract method 0x355274ea.

Solidity: function cap() view returns(uint256)

func (*TestERC20Caller) Decimals

func (_TestERC20 *TestERC20Caller) Decimals(opts *bind.CallOpts) (uint8, error)

Decimals is a free data retrieval call binding the contract method 0x313ce567.

Solidity: function decimals() view returns(uint8)

func (*TestERC20Caller) Name

func (_TestERC20 *TestERC20Caller) Name(opts *bind.CallOpts) (string, error)

Name is a free data retrieval call binding the contract method 0x06fdde03.

Solidity: function name() view returns(string)

func (*TestERC20Caller) Symbol

func (_TestERC20 *TestERC20Caller) Symbol(opts *bind.CallOpts) (string, error)

Symbol is a free data retrieval call binding the contract method 0x95d89b41.

Solidity: function symbol() view returns(string)

func (*TestERC20Caller) TotalSupply

func (_TestERC20 *TestERC20Caller) TotalSupply(opts *bind.CallOpts) (*big.Int, error)

TotalSupply is a free data retrieval call binding the contract method 0x18160ddd.

Solidity: function totalSupply() view returns(uint256)

type TestERC20CallerRaw

type TestERC20CallerRaw struct {
	Contract *TestERC20Caller // Generic read-only contract binding to access the raw methods on
}

TestERC20CallerRaw is an auto generated low-level read-only Go binding around an Ethereum contract.

func (*TestERC20CallerRaw) Call

func (_TestERC20 *TestERC20CallerRaw) Call(opts *bind.CallOpts, result *[]interface{}, method string, params ...interface{}) error

Call invokes the (constant) contract method with params as input values and sets the output to result. The result type might be a single field for simple returns, a slice of interfaces for anonymous returns and a struct for named returns.

type TestERC20CallerSession

type TestERC20CallerSession struct {
	Contract *TestERC20Caller // Generic contract caller binding to set the session for
	CallOpts bind.CallOpts    // Call options to use throughout this session
}

TestERC20CallerSession is an auto generated read-only Go binding around an Ethereum contract, with pre-set call options.

func (*TestERC20CallerSession) Allowance

func (_TestERC20 *TestERC20CallerSession) Allowance(owner common.Address, spender common.Address) (*big.Int, error)

Allowance is a free data retrieval call binding the contract method 0xdd62ed3e.

Solidity: function allowance(address owner, address spender) view returns(uint256)

func (*TestERC20CallerSession) BalanceOf

func (_TestERC20 *TestERC20CallerSession) BalanceOf(account common.Address) (*big.Int, error)

BalanceOf is a free data retrieval call binding the contract method 0x70a08231.

Solidity: function balanceOf(address account) view returns(uint256)

func (*TestERC20CallerSession) Cap

func (_TestERC20 *TestERC20CallerSession) Cap() (*big.Int, error)

Cap is a free data retrieval call binding the contract method 0x355274ea.

Solidity: function cap() view returns(uint256)

func (*TestERC20CallerSession) Decimals

func (_TestERC20 *TestERC20CallerSession) Decimals() (uint8, error)

Decimals is a free data retrieval call binding the contract method 0x313ce567.

Solidity: function decimals() view returns(uint8)

func (*TestERC20CallerSession) Name

func (_TestERC20 *TestERC20CallerSession) Name() (string, error)

Name is a free data retrieval call binding the contract method 0x06fdde03.

Solidity: function name() view returns(string)

func (*TestERC20CallerSession) Symbol

func (_TestERC20 *TestERC20CallerSession) Symbol() (string, error)

Symbol is a free data retrieval call binding the contract method 0x95d89b41.

Solidity: function symbol() view returns(string)

func (*TestERC20CallerSession) TotalSupply

func (_TestERC20 *TestERC20CallerSession) TotalSupply() (*big.Int, error)

TotalSupply is a free data retrieval call binding the contract method 0x18160ddd.

Solidity: function totalSupply() view returns(uint256)

type TestERC20Filterer

type TestERC20Filterer struct {
	// contains filtered or unexported fields
}

TestERC20Filterer is an auto generated log filtering Go binding around an Ethereum contract events.

func NewTestERC20Filterer

func NewTestERC20Filterer(address common.Address, filterer bind.ContractFilterer) (*TestERC20Filterer, error)

NewTestERC20Filterer creates a new log filterer instance of TestERC20, bound to a specific deployed contract.

func (*TestERC20Filterer) FilterApproval

func (_TestERC20 *TestERC20Filterer) FilterApproval(opts *bind.FilterOpts, owner []common.Address, spender []common.Address) (*TestERC20ApprovalIterator, error)

FilterApproval is a free log retrieval operation binding the contract event 0x8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925.

Solidity: event Approval(address indexed owner, address indexed spender, uint256 value)

func (*TestERC20Filterer) FilterTransfer

func (_TestERC20 *TestERC20Filterer) FilterTransfer(opts *bind.FilterOpts, from []common.Address, to []common.Address) (*TestERC20TransferIterator, error)

FilterTransfer is a free log retrieval operation binding the contract event 0xddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef.

Solidity: event Transfer(address indexed from, address indexed to, uint256 value)

func (*TestERC20Filterer) ParseApproval

func (_TestERC20 *TestERC20Filterer) ParseApproval(log types.Log) (*TestERC20Approval, error)

ParseApproval is a log parse operation binding the contract event 0x8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925.

Solidity: event Approval(address indexed owner, address indexed spender, uint256 value)

func (*TestERC20Filterer) ParseTransfer

func (_TestERC20 *TestERC20Filterer) ParseTransfer(log types.Log) (*TestERC20Transfer, error)

ParseTransfer is a log parse operation binding the contract event 0xddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef.

Solidity: event Transfer(address indexed from, address indexed to, uint256 value)

func (*TestERC20Filterer) WatchApproval

func (_TestERC20 *TestERC20Filterer) WatchApproval(opts *bind.WatchOpts, sink chan<- *TestERC20Approval, owner []common.Address, spender []common.Address) (event.Subscription, error)

WatchApproval is a free log subscription operation binding the contract event 0x8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925.

Solidity: event Approval(address indexed owner, address indexed spender, uint256 value)

func (*TestERC20Filterer) WatchTransfer

func (_TestERC20 *TestERC20Filterer) WatchTransfer(opts *bind.WatchOpts, sink chan<- *TestERC20Transfer, from []common.Address, to []common.Address) (event.Subscription, error)

WatchTransfer is a free log subscription operation binding the contract event 0xddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef.

Solidity: event Transfer(address indexed from, address indexed to, uint256 value)

type TestERC20Raw

type TestERC20Raw struct {
	Contract *TestERC20 // Generic contract binding to access the raw methods on
}

TestERC20Raw is an auto generated low-level Go binding around an Ethereum contract.

func (*TestERC20Raw) Call

func (_TestERC20 *TestERC20Raw) Call(opts *bind.CallOpts, result *[]interface{}, method string, params ...interface{}) error

Call invokes the (constant) contract method with params as input values and sets the output to result. The result type might be a single field for simple returns, a slice of interfaces for anonymous returns and a struct for named returns.

func (*TestERC20Raw) Transact

func (_TestERC20 *TestERC20Raw) Transact(opts *bind.TransactOpts, method string, params ...interface{}) (*types.Transaction, error)

Transact invokes the (paid) contract method with params as input values.

func (*TestERC20Raw) Transfer

func (_TestERC20 *TestERC20Raw) Transfer(opts *bind.TransactOpts) (*types.Transaction, error)

Transfer initiates a plain transaction to move funds to the contract, calling its default method if one is available.

type TestERC20Session

type TestERC20Session struct {
	Contract     *TestERC20        // Generic contract binding to set the session for
	CallOpts     bind.CallOpts     // Call options to use throughout this session
	TransactOpts bind.TransactOpts // Transaction auth options to use throughout this session
}

TestERC20Session is an auto generated Go binding around an Ethereum contract, with pre-set call and transact options.

func (*TestERC20Session) Allowance

func (_TestERC20 *TestERC20Session) Allowance(owner common.Address, spender common.Address) (*big.Int, error)

Allowance is a free data retrieval call binding the contract method 0xdd62ed3e.

Solidity: function allowance(address owner, address spender) view returns(uint256)

func (*TestERC20Session) Approve

func (_TestERC20 *TestERC20Session) Approve(spender common.Address, value *big.Int) (*types.Transaction, error)

Approve is a paid mutator transaction binding the contract method 0x095ea7b3.

Solidity: function approve(address spender, uint256 value) returns(bool)

func (*TestERC20Session) BalanceOf

func (_TestERC20 *TestERC20Session) BalanceOf(account common.Address) (*big.Int, error)

BalanceOf is a free data retrieval call binding the contract method 0x70a08231.

Solidity: function balanceOf(address account) view returns(uint256)

func (*TestERC20Session) Burn

func (_TestERC20 *TestERC20Session) Burn(account common.Address, amount *big.Int) (*types.Transaction, error)

Burn is a paid mutator transaction binding the contract method 0x9dc29fac.

Solidity: function burn(address account, uint256 amount) returns()

func (*TestERC20Session) Cap

func (_TestERC20 *TestERC20Session) Cap() (*big.Int, error)

Cap is a free data retrieval call binding the contract method 0x355274ea.

Solidity: function cap() view returns(uint256)

func (*TestERC20Session) Decimals

func (_TestERC20 *TestERC20Session) Decimals() (uint8, error)

Decimals is a free data retrieval call binding the contract method 0x313ce567.

Solidity: function decimals() view returns(uint8)

func (*TestERC20Session) Mint

func (_TestERC20 *TestERC20Session) Mint(account common.Address, amount *big.Int) (*types.Transaction, error)

Mint is a paid mutator transaction binding the contract method 0x40c10f19.

Solidity: function mint(address account, uint256 amount) returns()

func (*TestERC20Session) Name

func (_TestERC20 *TestERC20Session) Name() (string, error)

Name is a free data retrieval call binding the contract method 0x06fdde03.

Solidity: function name() view returns(string)

func (*TestERC20Session) Symbol

func (_TestERC20 *TestERC20Session) Symbol() (string, error)

Symbol is a free data retrieval call binding the contract method 0x95d89b41.

Solidity: function symbol() view returns(string)

func (*TestERC20Session) TotalSupply

func (_TestERC20 *TestERC20Session) TotalSupply() (*big.Int, error)

TotalSupply is a free data retrieval call binding the contract method 0x18160ddd.

Solidity: function totalSupply() view returns(uint256)

func (*TestERC20Session) Transfer

func (_TestERC20 *TestERC20Session) Transfer(to common.Address, value *big.Int) (*types.Transaction, error)

Transfer is a paid mutator transaction binding the contract method 0xa9059cbb.

Solidity: function transfer(address to, uint256 value) returns(bool)

func (*TestERC20Session) TransferFrom

func (_TestERC20 *TestERC20Session) TransferFrom(from common.Address, to common.Address, value *big.Int) (*types.Transaction, error)

TransferFrom is a paid mutator transaction binding the contract method 0x23b872dd.

Solidity: function transferFrom(address from, address to, uint256 value) returns(bool)

type TestERC20Transactor

type TestERC20Transactor struct {
	// contains filtered or unexported fields
}

TestERC20Transactor is an auto generated write-only Go binding around an Ethereum contract.

func NewTestERC20Transactor

func NewTestERC20Transactor(address common.Address, transactor bind.ContractTransactor) (*TestERC20Transactor, error)

NewTestERC20Transactor creates a new write-only instance of TestERC20, bound to a specific deployed contract.

func (*TestERC20Transactor) Approve

func (_TestERC20 *TestERC20Transactor) Approve(opts *bind.TransactOpts, spender common.Address, value *big.Int) (*types.Transaction, error)

Approve is a paid mutator transaction binding the contract method 0x095ea7b3.

Solidity: function approve(address spender, uint256 value) returns(bool)

func (*TestERC20Transactor) Burn

func (_TestERC20 *TestERC20Transactor) Burn(opts *bind.TransactOpts, account common.Address, amount *big.Int) (*types.Transaction, error)

Burn is a paid mutator transaction binding the contract method 0x9dc29fac.

Solidity: function burn(address account, uint256 amount) returns()

func (*TestERC20Transactor) Mint

func (_TestERC20 *TestERC20Transactor) Mint(opts *bind.TransactOpts, account common.Address, amount *big.Int) (*types.Transaction, error)

Mint is a paid mutator transaction binding the contract method 0x40c10f19.

Solidity: function mint(address account, uint256 amount) returns()

func (*TestERC20Transactor) Transfer

func (_TestERC20 *TestERC20Transactor) Transfer(opts *bind.TransactOpts, to common.Address, value *big.Int) (*types.Transaction, error)

Transfer is a paid mutator transaction binding the contract method 0xa9059cbb.

Solidity: function transfer(address to, uint256 value) returns(bool)

func (*TestERC20Transactor) TransferFrom

func (_TestERC20 *TestERC20Transactor) TransferFrom(opts *bind.TransactOpts, from common.Address, to common.Address, value *big.Int) (*types.Transaction, error)

TransferFrom is a paid mutator transaction binding the contract method 0x23b872dd.

Solidity: function transferFrom(address from, address to, uint256 value) returns(bool)

type TestERC20TransactorRaw

type TestERC20TransactorRaw struct {
	Contract *TestERC20Transactor // Generic write-only contract binding to access the raw methods on
}

TestERC20TransactorRaw is an auto generated low-level write-only Go binding around an Ethereum contract.

func (*TestERC20TransactorRaw) Transact

func (_TestERC20 *TestERC20TransactorRaw) Transact(opts *bind.TransactOpts, method string, params ...interface{}) (*types.Transaction, error)

Transact invokes the (paid) contract method with params as input values.

func (*TestERC20TransactorRaw) Transfer

func (_TestERC20 *TestERC20TransactorRaw) Transfer(opts *bind.TransactOpts) (*types.Transaction, error)

Transfer initiates a plain transaction to move funds to the contract, calling its default method if one is available.

type TestERC20TransactorSession

type TestERC20TransactorSession struct {
	Contract     *TestERC20Transactor // Generic contract transactor binding to set the session for
	TransactOpts bind.TransactOpts    // Transaction auth options to use throughout this session
}

TestERC20TransactorSession is an auto generated write-only Go binding around an Ethereum contract, with pre-set transact options.

func (*TestERC20TransactorSession) Approve

func (_TestERC20 *TestERC20TransactorSession) Approve(spender common.Address, value *big.Int) (*types.Transaction, error)

Approve is a paid mutator transaction binding the contract method 0x095ea7b3.

Solidity: function approve(address spender, uint256 value) returns(bool)

func (*TestERC20TransactorSession) Burn

func (_TestERC20 *TestERC20TransactorSession) Burn(account common.Address, amount *big.Int) (*types.Transaction, error)

Burn is a paid mutator transaction binding the contract method 0x9dc29fac.

Solidity: function burn(address account, uint256 amount) returns()

func (*TestERC20TransactorSession) Mint

func (_TestERC20 *TestERC20TransactorSession) Mint(account common.Address, amount *big.Int) (*types.Transaction, error)

Mint is a paid mutator transaction binding the contract method 0x40c10f19.

Solidity: function mint(address account, uint256 amount) returns()

func (*TestERC20TransactorSession) Transfer

func (_TestERC20 *TestERC20TransactorSession) Transfer(to common.Address, value *big.Int) (*types.Transaction, error)

Transfer is a paid mutator transaction binding the contract method 0xa9059cbb.

Solidity: function transfer(address to, uint256 value) returns(bool)

func (*TestERC20TransactorSession) TransferFrom

func (_TestERC20 *TestERC20TransactorSession) TransferFrom(from common.Address, to common.Address, value *big.Int) (*types.Transaction, error)

TransferFrom is a paid mutator transaction binding the contract method 0x23b872dd.

Solidity: function transferFrom(address from, address to, uint256 value) returns(bool)

type TestERC20Transfer

type TestERC20Transfer struct {
	From  common.Address
	To    common.Address
	Value *big.Int
	Raw   types.Log // Blockchain specific contextual infos
}

TestERC20Transfer represents a Transfer event raised by the TestERC20 contract.

type TestERC20TransferIterator

type TestERC20TransferIterator struct {
	Event *TestERC20Transfer // Event containing the contract specifics and raw log
	// contains filtered or unexported fields
}

TestERC20TransferIterator is returned from FilterTransfer and is used to iterate over the raw logs and unpacked data for Transfer events raised by the TestERC20 contract.

func (*TestERC20TransferIterator) Close

func (it *TestERC20TransferIterator) Close() error

Close terminates the iteration process, releasing any pending underlying resources.

func (*TestERC20TransferIterator) Error

func (it *TestERC20TransferIterator) Error() error

Error returns any retrieval or parsing error occurred during filtering.

func (*TestERC20TransferIterator) Next

func (it *TestERC20TransferIterator) Next() bool

Next advances the iterator to the subsequent event, returning whether there are any more events found. In case of a retrieval or parsing error, false is returned and Error() can be queried for the exact failure.

Jump to

Keyboard shortcuts

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