2019-11-04 10:08:22 +00:00
|
|
|
// Code generated - DO NOT EDIT.
|
|
|
|
// This file is a generated binding and any manual changes will be lost.
|
|
|
|
|
|
|
|
package reverseregistrar
|
|
|
|
|
|
|
|
import (
|
|
|
|
"math/big"
|
|
|
|
"strings"
|
|
|
|
|
|
|
|
ethereum "github.com/ethereum/go-ethereum"
|
|
|
|
"github.com/ethereum/go-ethereum/accounts/abi"
|
|
|
|
"github.com/ethereum/go-ethereum/accounts/abi/bind"
|
|
|
|
"github.com/ethereum/go-ethereum/common"
|
|
|
|
"github.com/ethereum/go-ethereum/core/types"
|
|
|
|
"github.com/ethereum/go-ethereum/event"
|
|
|
|
)
|
|
|
|
|
|
|
|
// Reference imports to suppress errors if they are not otherwise used.
|
|
|
|
var (
|
|
|
|
_ = big.NewInt
|
|
|
|
_ = strings.NewReader
|
|
|
|
_ = ethereum.NotFound
|
|
|
|
_ = bind.Bind
|
|
|
|
_ = common.Big1
|
|
|
|
_ = types.BloomLookup
|
|
|
|
_ = event.NewSubscription
|
|
|
|
)
|
|
|
|
|
|
|
|
// ContractABI is the input ABI used to generate the binding from.
|
|
|
|
const ContractABI = "[{\"constant\":false,\"inputs\":[{\"name\":\"owner\",\"type\":\"address\"},{\"name\":\"resolver\",\"type\":\"address\"}],\"name\":\"claimWithResolver\",\"outputs\":[{\"name\":\"node\",\"type\":\"bytes32\"}],\"payable\":false,\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"owner\",\"type\":\"address\"}],\"name\":\"claim\",\"outputs\":[{\"name\":\"node\",\"type\":\"bytes32\"}],\"payable\":false,\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"ens\",\"outputs\":[{\"name\":\"\",\"type\":\"address\"}],\"payable\":false,\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"defaultResolver\",\"outputs\":[{\"name\":\"\",\"type\":\"address\"}],\"payable\":false,\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"name\":\"addr\",\"type\":\"address\"}],\"name\":\"node\",\"outputs\":[{\"name\":\"ret\",\"type\":\"bytes32\"}],\"payable\":false,\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"name\",\"type\":\"string\"}],\"name\":\"setName\",\"outputs\":[{\"name\":\"node\",\"type\":\"bytes32\"}],\"payable\":false,\"type\":\"function\"},{\"inputs\":[{\"name\":\"ensAddr\",\"type\":\"address\"},{\"name\":\"resolverAddr\",\"type\":\"address\"}],\"payable\":false,\"type\":\"constructor\"}]"
|
|
|
|
|
|
|
|
// Contract is an auto generated Go binding around an Ethereum contract.
|
|
|
|
type Contract struct {
|
|
|
|
ContractCaller // Read-only binding to the contract
|
|
|
|
ContractTransactor // Write-only binding to the contract
|
|
|
|
ContractFilterer // Log filterer for contract events
|
|
|
|
}
|
|
|
|
|
|
|
|
// ContractCaller is an auto generated read-only Go binding around an Ethereum contract.
|
|
|
|
type ContractCaller struct {
|
|
|
|
contract *bind.BoundContract // Generic contract wrapper for the low level calls
|
|
|
|
}
|
|
|
|
|
|
|
|
// ContractTransactor is an auto generated write-only Go binding around an Ethereum contract.
|
|
|
|
type ContractTransactor struct {
|
|
|
|
contract *bind.BoundContract // Generic contract wrapper for the low level calls
|
|
|
|
}
|
|
|
|
|
|
|
|
// ContractFilterer is an auto generated log filtering Go binding around an Ethereum contract events.
|
|
|
|
type ContractFilterer struct {
|
|
|
|
contract *bind.BoundContract // Generic contract wrapper for the low level calls
|
|
|
|
}
|
|
|
|
|
|
|
|
// ContractSession is an auto generated Go binding around an Ethereum contract,
|
|
|
|
// with pre-set call and transact options.
|
|
|
|
type ContractSession struct {
|
|
|
|
Contract *Contract // 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
|
|
|
|
}
|
|
|
|
|
|
|
|
// ContractCallerSession is an auto generated read-only Go binding around an Ethereum contract,
|
|
|
|
// with pre-set call options.
|
|
|
|
type ContractCallerSession struct {
|
|
|
|
Contract *ContractCaller // Generic contract caller binding to set the session for
|
|
|
|
CallOpts bind.CallOpts // Call options to use throughout this session
|
|
|
|
}
|
|
|
|
|
|
|
|
// ContractTransactorSession is an auto generated write-only Go binding around an Ethereum contract,
|
|
|
|
// with pre-set transact options.
|
|
|
|
type ContractTransactorSession struct {
|
|
|
|
Contract *ContractTransactor // Generic contract transactor binding to set the session for
|
|
|
|
TransactOpts bind.TransactOpts // Transaction auth options to use throughout this session
|
|
|
|
}
|
|
|
|
|
|
|
|
// ContractRaw is an auto generated low-level Go binding around an Ethereum contract.
|
|
|
|
type ContractRaw struct {
|
|
|
|
Contract *Contract // Generic contract binding to access the raw methods on
|
|
|
|
}
|
|
|
|
|
|
|
|
// ContractCallerRaw is an auto generated low-level read-only Go binding around an Ethereum contract.
|
|
|
|
type ContractCallerRaw struct {
|
|
|
|
Contract *ContractCaller // Generic read-only contract binding to access the raw methods on
|
|
|
|
}
|
|
|
|
|
|
|
|
// ContractTransactorRaw is an auto generated low-level write-only Go binding around an Ethereum contract.
|
|
|
|
type ContractTransactorRaw struct {
|
|
|
|
Contract *ContractTransactor // Generic write-only contract binding to access the raw methods on
|
|
|
|
}
|
|
|
|
|
|
|
|
// NewContract creates a new instance of Contract, bound to a specific deployed contract.
|
|
|
|
func NewContract(address common.Address, backend bind.ContractBackend) (*Contract, error) {
|
|
|
|
contract, err := bindContract(address, backend, backend, backend)
|
|
|
|
if err != nil {
|
|
|
|
return nil, err
|
|
|
|
}
|
|
|
|
return &Contract{ContractCaller: ContractCaller{contract: contract}, ContractTransactor: ContractTransactor{contract: contract}, ContractFilterer: ContractFilterer{contract: contract}}, nil
|
|
|
|
}
|
|
|
|
|
|
|
|
// NewContractCaller creates a new read-only instance of Contract, bound to a specific deployed contract.
|
|
|
|
func NewContractCaller(address common.Address, caller bind.ContractCaller) (*ContractCaller, error) {
|
|
|
|
contract, err := bindContract(address, caller, nil, nil)
|
|
|
|
if err != nil {
|
|
|
|
return nil, err
|
|
|
|
}
|
|
|
|
return &ContractCaller{contract: contract}, nil
|
|
|
|
}
|
|
|
|
|
|
|
|
// NewContractTransactor creates a new write-only instance of Contract, bound to a specific deployed contract.
|
|
|
|
func NewContractTransactor(address common.Address, transactor bind.ContractTransactor) (*ContractTransactor, error) {
|
|
|
|
contract, err := bindContract(address, nil, transactor, nil)
|
|
|
|
if err != nil {
|
|
|
|
return nil, err
|
|
|
|
}
|
|
|
|
return &ContractTransactor{contract: contract}, nil
|
|
|
|
}
|
|
|
|
|
|
|
|
// NewContractFilterer creates a new log filterer instance of Contract, bound to a specific deployed contract.
|
|
|
|
func NewContractFilterer(address common.Address, filterer bind.ContractFilterer) (*ContractFilterer, error) {
|
|
|
|
contract, err := bindContract(address, nil, nil, filterer)
|
|
|
|
if err != nil {
|
|
|
|
return nil, err
|
|
|
|
}
|
|
|
|
return &ContractFilterer{contract: contract}, nil
|
|
|
|
}
|
|
|
|
|
|
|
|
// bindContract binds a generic wrapper to an already deployed contract.
|
|
|
|
func bindContract(address common.Address, caller bind.ContractCaller, transactor bind.ContractTransactor, filterer bind.ContractFilterer) (*bind.BoundContract, error) {
|
|
|
|
parsed, err := abi.JSON(strings.NewReader(ContractABI))
|
|
|
|
if err != nil {
|
|
|
|
return nil, err
|
|
|
|
}
|
|
|
|
return bind.NewBoundContract(address, parsed, caller, transactor, filterer), nil
|
|
|
|
}
|
|
|
|
|
|
|
|
// 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.
|
2021-06-28 06:53:50 +00:00
|
|
|
func (_Contract *ContractRaw) Call(opts *bind.CallOpts, result *[]interface{}, method string, params ...interface{}) error {
|
2019-11-04 10:08:22 +00:00
|
|
|
return _Contract.Contract.ContractCaller.contract.Call(opts, result, method, params...)
|
|
|
|
}
|
|
|
|
|
|
|
|
// Transfer initiates a plain transaction to move funds to the contract, calling
|
|
|
|
// its default method if one is available.
|
|
|
|
func (_Contract *ContractRaw) Transfer(opts *bind.TransactOpts) (*types.Transaction, error) {
|
|
|
|
return _Contract.Contract.ContractTransactor.contract.Transfer(opts)
|
|
|
|
}
|
|
|
|
|
|
|
|
// Transact invokes the (paid) contract method with params as input values.
|
|
|
|
func (_Contract *ContractRaw) Transact(opts *bind.TransactOpts, method string, params ...interface{}) (*types.Transaction, error) {
|
|
|
|
return _Contract.Contract.ContractTransactor.contract.Transact(opts, method, params...)
|
|
|
|
}
|
|
|
|
|
|
|
|
// 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.
|
2021-06-28 06:53:50 +00:00
|
|
|
func (_Contract *ContractCallerRaw) Call(opts *bind.CallOpts, result *[]interface{}, method string, params ...interface{}) error {
|
2019-11-04 10:08:22 +00:00
|
|
|
return _Contract.Contract.contract.Call(opts, result, method, params...)
|
|
|
|
}
|
|
|
|
|
|
|
|
// Transfer initiates a plain transaction to move funds to the contract, calling
|
|
|
|
// its default method if one is available.
|
|
|
|
func (_Contract *ContractTransactorRaw) Transfer(opts *bind.TransactOpts) (*types.Transaction, error) {
|
|
|
|
return _Contract.Contract.contract.Transfer(opts)
|
|
|
|
}
|
|
|
|
|
|
|
|
// Transact invokes the (paid) contract method with params as input values.
|
|
|
|
func (_Contract *ContractTransactorRaw) Transact(opts *bind.TransactOpts, method string, params ...interface{}) (*types.Transaction, error) {
|
|
|
|
return _Contract.Contract.contract.Transact(opts, method, params...)
|
|
|
|
}
|
|
|
|
|
|
|
|
// DefaultResolver is a free data retrieval call binding the contract method 0x828eab0e.
|
|
|
|
//
|
2021-06-28 06:53:50 +00:00
|
|
|
// Solidity: function defaultResolver() returns(address)
|
2019-11-04 10:08:22 +00:00
|
|
|
func (_Contract *ContractCaller) DefaultResolver(opts *bind.CallOpts) (common.Address, error) {
|
2021-06-28 06:53:50 +00:00
|
|
|
var out []interface{}
|
|
|
|
err := _Contract.contract.Call(opts, &out, "defaultResolver")
|
|
|
|
|
|
|
|
if err != nil {
|
|
|
|
return *new(common.Address), err
|
|
|
|
}
|
|
|
|
|
|
|
|
out0 := *abi.ConvertType(out[0], new(common.Address)).(*common.Address)
|
|
|
|
|
|
|
|
return out0, err
|
|
|
|
|
2019-11-04 10:08:22 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
// DefaultResolver is a free data retrieval call binding the contract method 0x828eab0e.
|
|
|
|
//
|
2021-06-28 06:53:50 +00:00
|
|
|
// Solidity: function defaultResolver() returns(address)
|
2019-11-04 10:08:22 +00:00
|
|
|
func (_Contract *ContractSession) DefaultResolver() (common.Address, error) {
|
|
|
|
return _Contract.Contract.DefaultResolver(&_Contract.CallOpts)
|
|
|
|
}
|
|
|
|
|
|
|
|
// DefaultResolver is a free data retrieval call binding the contract method 0x828eab0e.
|
|
|
|
//
|
2021-06-28 06:53:50 +00:00
|
|
|
// Solidity: function defaultResolver() returns(address)
|
2019-11-04 10:08:22 +00:00
|
|
|
func (_Contract *ContractCallerSession) DefaultResolver() (common.Address, error) {
|
|
|
|
return _Contract.Contract.DefaultResolver(&_Contract.CallOpts)
|
|
|
|
}
|
|
|
|
|
|
|
|
// Ens is a free data retrieval call binding the contract method 0x3f15457f.
|
|
|
|
//
|
2021-06-28 06:53:50 +00:00
|
|
|
// Solidity: function ens() returns(address)
|
2019-11-04 10:08:22 +00:00
|
|
|
func (_Contract *ContractCaller) Ens(opts *bind.CallOpts) (common.Address, error) {
|
2021-06-28 06:53:50 +00:00
|
|
|
var out []interface{}
|
|
|
|
err := _Contract.contract.Call(opts, &out, "ens")
|
|
|
|
|
|
|
|
if err != nil {
|
|
|
|
return *new(common.Address), err
|
|
|
|
}
|
|
|
|
|
|
|
|
out0 := *abi.ConvertType(out[0], new(common.Address)).(*common.Address)
|
|
|
|
|
|
|
|
return out0, err
|
|
|
|
|
2019-11-04 10:08:22 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
// Ens is a free data retrieval call binding the contract method 0x3f15457f.
|
|
|
|
//
|
2021-06-28 06:53:50 +00:00
|
|
|
// Solidity: function ens() returns(address)
|
2019-11-04 10:08:22 +00:00
|
|
|
func (_Contract *ContractSession) Ens() (common.Address, error) {
|
|
|
|
return _Contract.Contract.Ens(&_Contract.CallOpts)
|
|
|
|
}
|
|
|
|
|
|
|
|
// Ens is a free data retrieval call binding the contract method 0x3f15457f.
|
|
|
|
//
|
2021-06-28 06:53:50 +00:00
|
|
|
// Solidity: function ens() returns(address)
|
2019-11-04 10:08:22 +00:00
|
|
|
func (_Contract *ContractCallerSession) Ens() (common.Address, error) {
|
|
|
|
return _Contract.Contract.Ens(&_Contract.CallOpts)
|
|
|
|
}
|
|
|
|
|
|
|
|
// Node is a free data retrieval call binding the contract method 0xbffbe61c.
|
|
|
|
//
|
2021-06-28 06:53:50 +00:00
|
|
|
// Solidity: function node(address addr) returns(bytes32 ret)
|
2019-11-04 10:08:22 +00:00
|
|
|
func (_Contract *ContractCaller) Node(opts *bind.CallOpts, addr common.Address) ([32]byte, error) {
|
2021-06-28 06:53:50 +00:00
|
|
|
var out []interface{}
|
|
|
|
err := _Contract.contract.Call(opts, &out, "node", addr)
|
|
|
|
|
|
|
|
if err != nil {
|
|
|
|
return *new([32]byte), err
|
|
|
|
}
|
|
|
|
|
|
|
|
out0 := *abi.ConvertType(out[0], new([32]byte)).(*[32]byte)
|
|
|
|
|
|
|
|
return out0, err
|
|
|
|
|
2019-11-04 10:08:22 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
// Node is a free data retrieval call binding the contract method 0xbffbe61c.
|
|
|
|
//
|
2021-06-28 06:53:50 +00:00
|
|
|
// Solidity: function node(address addr) returns(bytes32 ret)
|
2019-11-04 10:08:22 +00:00
|
|
|
func (_Contract *ContractSession) Node(addr common.Address) ([32]byte, error) {
|
|
|
|
return _Contract.Contract.Node(&_Contract.CallOpts, addr)
|
|
|
|
}
|
|
|
|
|
|
|
|
// Node is a free data retrieval call binding the contract method 0xbffbe61c.
|
|
|
|
//
|
2021-06-28 06:53:50 +00:00
|
|
|
// Solidity: function node(address addr) returns(bytes32 ret)
|
2019-11-04 10:08:22 +00:00
|
|
|
func (_Contract *ContractCallerSession) Node(addr common.Address) ([32]byte, error) {
|
|
|
|
return _Contract.Contract.Node(&_Contract.CallOpts, addr)
|
|
|
|
}
|
|
|
|
|
|
|
|
// Claim is a paid mutator transaction binding the contract method 0x1e83409a.
|
|
|
|
//
|
|
|
|
// Solidity: function claim(address owner) returns(bytes32 node)
|
|
|
|
func (_Contract *ContractTransactor) Claim(opts *bind.TransactOpts, owner common.Address) (*types.Transaction, error) {
|
|
|
|
return _Contract.contract.Transact(opts, "claim", owner)
|
|
|
|
}
|
|
|
|
|
|
|
|
// Claim is a paid mutator transaction binding the contract method 0x1e83409a.
|
|
|
|
//
|
|
|
|
// Solidity: function claim(address owner) returns(bytes32 node)
|
|
|
|
func (_Contract *ContractSession) Claim(owner common.Address) (*types.Transaction, error) {
|
|
|
|
return _Contract.Contract.Claim(&_Contract.TransactOpts, owner)
|
|
|
|
}
|
|
|
|
|
|
|
|
// Claim is a paid mutator transaction binding the contract method 0x1e83409a.
|
|
|
|
//
|
|
|
|
// Solidity: function claim(address owner) returns(bytes32 node)
|
|
|
|
func (_Contract *ContractTransactorSession) Claim(owner common.Address) (*types.Transaction, error) {
|
|
|
|
return _Contract.Contract.Claim(&_Contract.TransactOpts, owner)
|
|
|
|
}
|
|
|
|
|
|
|
|
// ClaimWithResolver is a paid mutator transaction binding the contract method 0x0f5a5466.
|
|
|
|
//
|
|
|
|
// Solidity: function claimWithResolver(address owner, address resolver) returns(bytes32 node)
|
|
|
|
func (_Contract *ContractTransactor) ClaimWithResolver(opts *bind.TransactOpts, owner common.Address, resolver common.Address) (*types.Transaction, error) {
|
|
|
|
return _Contract.contract.Transact(opts, "claimWithResolver", owner, resolver)
|
|
|
|
}
|
|
|
|
|
|
|
|
// ClaimWithResolver is a paid mutator transaction binding the contract method 0x0f5a5466.
|
|
|
|
//
|
|
|
|
// Solidity: function claimWithResolver(address owner, address resolver) returns(bytes32 node)
|
|
|
|
func (_Contract *ContractSession) ClaimWithResolver(owner common.Address, resolver common.Address) (*types.Transaction, error) {
|
|
|
|
return _Contract.Contract.ClaimWithResolver(&_Contract.TransactOpts, owner, resolver)
|
|
|
|
}
|
|
|
|
|
|
|
|
// ClaimWithResolver is a paid mutator transaction binding the contract method 0x0f5a5466.
|
|
|
|
//
|
|
|
|
// Solidity: function claimWithResolver(address owner, address resolver) returns(bytes32 node)
|
|
|
|
func (_Contract *ContractTransactorSession) ClaimWithResolver(owner common.Address, resolver common.Address) (*types.Transaction, error) {
|
|
|
|
return _Contract.Contract.ClaimWithResolver(&_Contract.TransactOpts, owner, resolver)
|
|
|
|
}
|
|
|
|
|
|
|
|
// SetName is a paid mutator transaction binding the contract method 0xc47f0027.
|
|
|
|
//
|
|
|
|
// Solidity: function setName(string name) returns(bytes32 node)
|
|
|
|
func (_Contract *ContractTransactor) SetName(opts *bind.TransactOpts, name string) (*types.Transaction, error) {
|
|
|
|
return _Contract.contract.Transact(opts, "setName", name)
|
|
|
|
}
|
|
|
|
|
|
|
|
// SetName is a paid mutator transaction binding the contract method 0xc47f0027.
|
|
|
|
//
|
|
|
|
// Solidity: function setName(string name) returns(bytes32 node)
|
|
|
|
func (_Contract *ContractSession) SetName(name string) (*types.Transaction, error) {
|
|
|
|
return _Contract.Contract.SetName(&_Contract.TransactOpts, name)
|
|
|
|
}
|
|
|
|
|
|
|
|
// SetName is a paid mutator transaction binding the contract method 0xc47f0027.
|
|
|
|
//
|
|
|
|
// Solidity: function setName(string name) returns(bytes32 node)
|
|
|
|
func (_Contract *ContractTransactorSession) SetName(name string) (*types.Transaction, error) {
|
|
|
|
return _Contract.Contract.SetName(&_Contract.TransactOpts, name)
|
|
|
|
}
|