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 ethcontroller
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\":true,\"inputs\":[{\"name\":\"interfaceID\",\"type\":\"bytes4\"}],\"name\":\"supportsInterface\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"pure\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[],\"name\":\"withdraw\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"_prices\",\"type\":\"address\"}],\"name\":\"setPriceOracle\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[],\"name\":\"renounceOwnership\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"_minCommitmentAge\",\"type\":\"uint256\"},{\"name\":\"_maxCommitmentAge\",\"type\":\"uint256\"}],\"name\":\"setCommitmentAges\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"name\":\"\",\"type\":\"bytes32\"}],\"name\":\"commitments\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"name\":\"name\",\"type\":\"string\"},{\"name\":\"duration\",\"type\":\"uint256\"}],\"name\":\"rentPrice\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"name\",\"type\":\"string\"},{\"name\":\"owner\",\"type\":\"address\"},{\"name\":\"duration\",\"type\":\"uint256\"},{\"name\":\"secret\",\"type\":\"bytes32\"}],\"name\":\"register\",\"outputs\":[],\"payable\":true,\"stateMutability\":\"payable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"MIN_REGISTRATION_DURATION\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"minCommitmentAge\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"name\":\"\",\"type\":\"address\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"isOwner\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"name\":\"name\",\"type\":\"string\"}],\"name\":\"valid\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"name\",\"type\":\"string\"},{\"name\":\"duration\",\"type\":\"uint256\"}],\"name\":\"renew\",\"outputs\":[],\"payable\":true,\"stateMutability\":\"payable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"name\":\"name\",\"type\":\"string\"}],\"name\":\"available\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"maxCommitmentAge\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"commitment\",\"type\":\"bytes32\"}],\"name\":\"commit\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"newOwner\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"name\":\"name\",\"type\":\"string\"},{\"name\":\"owner\",\"type\":\"address\"},{\"name\":\"secret\",\"type\":\"bytes32\"}],\"name\":\"makeCommitment\",\"outputs\":[{\"name\":\"\",\"type\":\"bytes32\"}],\"payable\":false,\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"name\":\"_base\",\"type\":\" ad
// 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 ... )
}
// MINREGISTRATIONDURATION is a free data retrieval call binding the contract method 0x8a95b09f.
//
2021-06-28 06:53:50 +00:00
// Solidity: function MIN_REGISTRATION_DURATION() view returns(uint256)
2019-11-04 10:08:22 +00:00
func ( _Contract * ContractCaller ) MINREGISTRATIONDURATION ( opts * bind . CallOpts ) ( * big . Int , error ) {
2021-06-28 06:53:50 +00:00
var out [ ] interface { }
err := _Contract . contract . Call ( opts , & out , "MIN_REGISTRATION_DURATION" )
if err != nil {
return * new ( * big . Int ) , err
}
out0 := * abi . ConvertType ( out [ 0 ] , new ( * big . Int ) ) . ( * * big . Int )
return out0 , err
2019-11-04 10:08:22 +00:00
}
// MINREGISTRATIONDURATION is a free data retrieval call binding the contract method 0x8a95b09f.
//
2021-06-28 06:53:50 +00:00
// Solidity: function MIN_REGISTRATION_DURATION() view returns(uint256)
2019-11-04 10:08:22 +00:00
func ( _Contract * ContractSession ) MINREGISTRATIONDURATION ( ) ( * big . Int , error ) {
return _Contract . Contract . MINREGISTRATIONDURATION ( & _Contract . CallOpts )
}
// MINREGISTRATIONDURATION is a free data retrieval call binding the contract method 0x8a95b09f.
//
2021-06-28 06:53:50 +00:00
// Solidity: function MIN_REGISTRATION_DURATION() view returns(uint256)
2019-11-04 10:08:22 +00:00
func ( _Contract * ContractCallerSession ) MINREGISTRATIONDURATION ( ) ( * big . Int , error ) {
return _Contract . Contract . MINREGISTRATIONDURATION ( & _Contract . CallOpts )
}
// Available is a free data retrieval call binding the contract method 0xaeb8ce9b.
//
2021-06-28 06:53:50 +00:00
// Solidity: function available(string name) view returns(bool)
2019-11-04 10:08:22 +00:00
func ( _Contract * ContractCaller ) Available ( opts * bind . CallOpts , name string ) ( bool , error ) {
2021-06-28 06:53:50 +00:00
var out [ ] interface { }
err := _Contract . contract . Call ( opts , & out , "available" , name )
if err != nil {
return * new ( bool ) , err
}
out0 := * abi . ConvertType ( out [ 0 ] , new ( bool ) ) . ( * bool )
return out0 , err
2019-11-04 10:08:22 +00:00
}
// Available is a free data retrieval call binding the contract method 0xaeb8ce9b.
//
2021-06-28 06:53:50 +00:00
// Solidity: function available(string name) view returns(bool)
2019-11-04 10:08:22 +00:00
func ( _Contract * ContractSession ) Available ( name string ) ( bool , error ) {
return _Contract . Contract . Available ( & _Contract . CallOpts , name )
}
// Available is a free data retrieval call binding the contract method 0xaeb8ce9b.
//
2021-06-28 06:53:50 +00:00
// Solidity: function available(string name) view returns(bool)
2019-11-04 10:08:22 +00:00
func ( _Contract * ContractCallerSession ) Available ( name string ) ( bool , error ) {
return _Contract . Contract . Available ( & _Contract . CallOpts , name )
}
// Commitments is a free data retrieval call binding the contract method 0x839df945.
//
2021-06-28 06:53:50 +00:00
// Solidity: function commitments(bytes32 ) view returns(uint256)
2019-11-04 10:08:22 +00:00
func ( _Contract * ContractCaller ) Commitments ( opts * bind . CallOpts , arg0 [ 32 ] byte ) ( * big . Int , error ) {
2021-06-28 06:53:50 +00:00
var out [ ] interface { }
err := _Contract . contract . Call ( opts , & out , "commitments" , arg0 )
if err != nil {
return * new ( * big . Int ) , err
}
out0 := * abi . ConvertType ( out [ 0 ] , new ( * big . Int ) ) . ( * * big . Int )
return out0 , err
2019-11-04 10:08:22 +00:00
}
// Commitments is a free data retrieval call binding the contract method 0x839df945.
//
2021-06-28 06:53:50 +00:00
// Solidity: function commitments(bytes32 ) view returns(uint256)
2019-11-04 10:08:22 +00:00
func ( _Contract * ContractSession ) Commitments ( arg0 [ 32 ] byte ) ( * big . Int , error ) {
return _Contract . Contract . Commitments ( & _Contract . CallOpts , arg0 )
}
// Commitments is a free data retrieval call binding the contract method 0x839df945.
//
2021-06-28 06:53:50 +00:00
// Solidity: function commitments(bytes32 ) view returns(uint256)
2019-11-04 10:08:22 +00:00
func ( _Contract * ContractCallerSession ) Commitments ( arg0 [ 32 ] byte ) ( * big . Int , error ) {
return _Contract . Contract . Commitments ( & _Contract . CallOpts , arg0 )
}
// IsOwner is a free data retrieval call binding the contract method 0x8f32d59b.
//
2021-06-28 06:53:50 +00:00
// Solidity: function isOwner() view returns(bool)
2019-11-04 10:08:22 +00:00
func ( _Contract * ContractCaller ) IsOwner ( opts * bind . CallOpts ) ( bool , error ) {
2021-06-28 06:53:50 +00:00
var out [ ] interface { }
err := _Contract . contract . Call ( opts , & out , "isOwner" )
if err != nil {
return * new ( bool ) , err
}
out0 := * abi . ConvertType ( out [ 0 ] , new ( bool ) ) . ( * bool )
return out0 , err
2019-11-04 10:08:22 +00:00
}
// IsOwner is a free data retrieval call binding the contract method 0x8f32d59b.
//
2021-06-28 06:53:50 +00:00
// Solidity: function isOwner() view returns(bool)
2019-11-04 10:08:22 +00:00
func ( _Contract * ContractSession ) IsOwner ( ) ( bool , error ) {
return _Contract . Contract . IsOwner ( & _Contract . CallOpts )
}
// IsOwner is a free data retrieval call binding the contract method 0x8f32d59b.
//
2021-06-28 06:53:50 +00:00
// Solidity: function isOwner() view returns(bool)
2019-11-04 10:08:22 +00:00
func ( _Contract * ContractCallerSession ) IsOwner ( ) ( bool , error ) {
return _Contract . Contract . IsOwner ( & _Contract . CallOpts )
}
// MakeCommitment is a free data retrieval call binding the contract method 0xf49826be.
//
2021-06-28 06:53:50 +00:00
// Solidity: function makeCommitment(string name, address owner, bytes32 secret) pure returns(bytes32)
2019-11-04 10:08:22 +00:00
func ( _Contract * ContractCaller ) MakeCommitment ( opts * bind . CallOpts , name string , owner common . Address , secret [ 32 ] byte ) ( [ 32 ] byte , error ) {
2021-06-28 06:53:50 +00:00
var out [ ] interface { }
err := _Contract . contract . Call ( opts , & out , "makeCommitment" , name , owner , secret )
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
}
// MakeCommitment is a free data retrieval call binding the contract method 0xf49826be.
//
2021-06-28 06:53:50 +00:00
// Solidity: function makeCommitment(string name, address owner, bytes32 secret) pure returns(bytes32)
2019-11-04 10:08:22 +00:00
func ( _Contract * ContractSession ) MakeCommitment ( name string , owner common . Address , secret [ 32 ] byte ) ( [ 32 ] byte , error ) {
return _Contract . Contract . MakeCommitment ( & _Contract . CallOpts , name , owner , secret )
}
// MakeCommitment is a free data retrieval call binding the contract method 0xf49826be.
//
2021-06-28 06:53:50 +00:00
// Solidity: function makeCommitment(string name, address owner, bytes32 secret) pure returns(bytes32)
2019-11-04 10:08:22 +00:00
func ( _Contract * ContractCallerSession ) MakeCommitment ( name string , owner common . Address , secret [ 32 ] byte ) ( [ 32 ] byte , error ) {
return _Contract . Contract . MakeCommitment ( & _Contract . CallOpts , name , owner , secret )
}
// MaxCommitmentAge is a free data retrieval call binding the contract method 0xce1e09c0.
//
2021-06-28 06:53:50 +00:00
// Solidity: function maxCommitmentAge() view returns(uint256)
2019-11-04 10:08:22 +00:00
func ( _Contract * ContractCaller ) MaxCommitmentAge ( opts * bind . CallOpts ) ( * big . Int , error ) {
2021-06-28 06:53:50 +00:00
var out [ ] interface { }
err := _Contract . contract . Call ( opts , & out , "maxCommitmentAge" )
if err != nil {
return * new ( * big . Int ) , err
}
out0 := * abi . ConvertType ( out [ 0 ] , new ( * big . Int ) ) . ( * * big . Int )
return out0 , err
2019-11-04 10:08:22 +00:00
}
// MaxCommitmentAge is a free data retrieval call binding the contract method 0xce1e09c0.
//
2021-06-28 06:53:50 +00:00
// Solidity: function maxCommitmentAge() view returns(uint256)
2019-11-04 10:08:22 +00:00
func ( _Contract * ContractSession ) MaxCommitmentAge ( ) ( * big . Int , error ) {
return _Contract . Contract . MaxCommitmentAge ( & _Contract . CallOpts )
}
// MaxCommitmentAge is a free data retrieval call binding the contract method 0xce1e09c0.
//
2021-06-28 06:53:50 +00:00
// Solidity: function maxCommitmentAge() view returns(uint256)
2019-11-04 10:08:22 +00:00
func ( _Contract * ContractCallerSession ) MaxCommitmentAge ( ) ( * big . Int , error ) {
return _Contract . Contract . MaxCommitmentAge ( & _Contract . CallOpts )
}
// MinCommitmentAge is a free data retrieval call binding the contract method 0x8d839ffe.
//
2021-06-28 06:53:50 +00:00
// Solidity: function minCommitmentAge() view returns(uint256)
2019-11-04 10:08:22 +00:00
func ( _Contract * ContractCaller ) MinCommitmentAge ( opts * bind . CallOpts ) ( * big . Int , error ) {
2021-06-28 06:53:50 +00:00
var out [ ] interface { }
err := _Contract . contract . Call ( opts , & out , "minCommitmentAge" )
if err != nil {
return * new ( * big . Int ) , err
}
out0 := * abi . ConvertType ( out [ 0 ] , new ( * big . Int ) ) . ( * * big . Int )
return out0 , err
2019-11-04 10:08:22 +00:00
}
// MinCommitmentAge is a free data retrieval call binding the contract method 0x8d839ffe.
//
2021-06-28 06:53:50 +00:00
// Solidity: function minCommitmentAge() view returns(uint256)
2019-11-04 10:08:22 +00:00
func ( _Contract * ContractSession ) MinCommitmentAge ( ) ( * big . Int , error ) {
return _Contract . Contract . MinCommitmentAge ( & _Contract . CallOpts )
}
// MinCommitmentAge is a free data retrieval call binding the contract method 0x8d839ffe.
//
2021-06-28 06:53:50 +00:00
// Solidity: function minCommitmentAge() view returns(uint256)
2019-11-04 10:08:22 +00:00
func ( _Contract * ContractCallerSession ) MinCommitmentAge ( ) ( * big . Int , error ) {
return _Contract . Contract . MinCommitmentAge ( & _Contract . CallOpts )
}
// Owner is a free data retrieval call binding the contract method 0x8da5cb5b.
//
2021-06-28 06:53:50 +00:00
// Solidity: function owner() view returns(address)
2019-11-04 10:08:22 +00:00
func ( _Contract * ContractCaller ) Owner ( opts * bind . CallOpts ) ( common . Address , error ) {
2021-06-28 06:53:50 +00:00
var out [ ] interface { }
err := _Contract . contract . Call ( opts , & out , "owner" )
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
}
// Owner is a free data retrieval call binding the contract method 0x8da5cb5b.
//
2021-06-28 06:53:50 +00:00
// Solidity: function owner() view returns(address)
2019-11-04 10:08:22 +00:00
func ( _Contract * ContractSession ) Owner ( ) ( common . Address , error ) {
return _Contract . Contract . Owner ( & _Contract . CallOpts )
}
// Owner is a free data retrieval call binding the contract method 0x8da5cb5b.
//
2021-06-28 06:53:50 +00:00
// Solidity: function owner() view returns(address)
2019-11-04 10:08:22 +00:00
func ( _Contract * ContractCallerSession ) Owner ( ) ( common . Address , error ) {
return _Contract . Contract . Owner ( & _Contract . CallOpts )
}
// RentPrice is a free data retrieval call binding the contract method 0x83e7f6ff.
//
2021-06-28 06:53:50 +00:00
// Solidity: function rentPrice(string name, uint256 duration) view returns(uint256)
2019-11-04 10:08:22 +00:00
func ( _Contract * ContractCaller ) RentPrice ( opts * bind . CallOpts , name string , duration * big . Int ) ( * big . Int , error ) {
2021-06-28 06:53:50 +00:00
var out [ ] interface { }
err := _Contract . contract . Call ( opts , & out , "rentPrice" , name , duration )
if err != nil {
return * new ( * big . Int ) , err
}
out0 := * abi . ConvertType ( out [ 0 ] , new ( * big . Int ) ) . ( * * big . Int )
return out0 , err
2019-11-04 10:08:22 +00:00
}
// RentPrice is a free data retrieval call binding the contract method 0x83e7f6ff.
//
2021-06-28 06:53:50 +00:00
// Solidity: function rentPrice(string name, uint256 duration) view returns(uint256)
2019-11-04 10:08:22 +00:00
func ( _Contract * ContractSession ) RentPrice ( name string , duration * big . Int ) ( * big . Int , error ) {
return _Contract . Contract . RentPrice ( & _Contract . CallOpts , name , duration )
}
// RentPrice is a free data retrieval call binding the contract method 0x83e7f6ff.
//
2021-06-28 06:53:50 +00:00
// Solidity: function rentPrice(string name, uint256 duration) view returns(uint256)
2019-11-04 10:08:22 +00:00
func ( _Contract * ContractCallerSession ) RentPrice ( name string , duration * big . Int ) ( * big . Int , error ) {
return _Contract . Contract . RentPrice ( & _Contract . CallOpts , name , duration )
}
// SupportsInterface is a free data retrieval call binding the contract method 0x01ffc9a7.
//
2021-06-28 06:53:50 +00:00
// Solidity: function supportsInterface(bytes4 interfaceID) pure returns(bool)
2019-11-04 10:08:22 +00:00
func ( _Contract * ContractCaller ) SupportsInterface ( opts * bind . CallOpts , interfaceID [ 4 ] byte ) ( bool , error ) {
2021-06-28 06:53:50 +00:00
var out [ ] interface { }
err := _Contract . contract . Call ( opts , & out , "supportsInterface" , interfaceID )
if err != nil {
return * new ( bool ) , err
}
out0 := * abi . ConvertType ( out [ 0 ] , new ( bool ) ) . ( * bool )
return out0 , err
2019-11-04 10:08:22 +00:00
}
// SupportsInterface is a free data retrieval call binding the contract method 0x01ffc9a7.
//
2021-06-28 06:53:50 +00:00
// Solidity: function supportsInterface(bytes4 interfaceID) pure returns(bool)
2019-11-04 10:08:22 +00:00
func ( _Contract * ContractSession ) SupportsInterface ( interfaceID [ 4 ] byte ) ( bool , error ) {
return _Contract . Contract . SupportsInterface ( & _Contract . CallOpts , interfaceID )
}
// SupportsInterface is a free data retrieval call binding the contract method 0x01ffc9a7.
//
2021-06-28 06:53:50 +00:00
// Solidity: function supportsInterface(bytes4 interfaceID) pure returns(bool)
2019-11-04 10:08:22 +00:00
func ( _Contract * ContractCallerSession ) SupportsInterface ( interfaceID [ 4 ] byte ) ( bool , error ) {
return _Contract . Contract . SupportsInterface ( & _Contract . CallOpts , interfaceID )
}
// Valid is a free data retrieval call binding the contract method 0x9791c097.
//
2021-06-28 06:53:50 +00:00
// Solidity: function valid(string name) view returns(bool)
2019-11-04 10:08:22 +00:00
func ( _Contract * ContractCaller ) Valid ( opts * bind . CallOpts , name string ) ( bool , error ) {
2021-06-28 06:53:50 +00:00
var out [ ] interface { }
err := _Contract . contract . Call ( opts , & out , "valid" , name )
if err != nil {
return * new ( bool ) , err
}
out0 := * abi . ConvertType ( out [ 0 ] , new ( bool ) ) . ( * bool )
return out0 , err
2019-11-04 10:08:22 +00:00
}
// Valid is a free data retrieval call binding the contract method 0x9791c097.
//
2021-06-28 06:53:50 +00:00
// Solidity: function valid(string name) view returns(bool)
2019-11-04 10:08:22 +00:00
func ( _Contract * ContractSession ) Valid ( name string ) ( bool , error ) {
return _Contract . Contract . Valid ( & _Contract . CallOpts , name )
}
// Valid is a free data retrieval call binding the contract method 0x9791c097.
//
2021-06-28 06:53:50 +00:00
// Solidity: function valid(string name) view returns(bool)
2019-11-04 10:08:22 +00:00
func ( _Contract * ContractCallerSession ) Valid ( name string ) ( bool , error ) {
return _Contract . Contract . Valid ( & _Contract . CallOpts , name )
}
// Commit is a paid mutator transaction binding the contract method 0xf14fcbc8.
//
// Solidity: function commit(bytes32 commitment) returns()
func ( _Contract * ContractTransactor ) Commit ( opts * bind . TransactOpts , commitment [ 32 ] byte ) ( * types . Transaction , error ) {
return _Contract . contract . Transact ( opts , "commit" , commitment )
}
// Commit is a paid mutator transaction binding the contract method 0xf14fcbc8.
//
// Solidity: function commit(bytes32 commitment) returns()
func ( _Contract * ContractSession ) Commit ( commitment [ 32 ] byte ) ( * types . Transaction , error ) {
return _Contract . Contract . Commit ( & _Contract . TransactOpts , commitment )
}
// Commit is a paid mutator transaction binding the contract method 0xf14fcbc8.
//
// Solidity: function commit(bytes32 commitment) returns()
func ( _Contract * ContractTransactorSession ) Commit ( commitment [ 32 ] byte ) ( * types . Transaction , error ) {
return _Contract . Contract . Commit ( & _Contract . TransactOpts , commitment )
}
// Register is a paid mutator transaction binding the contract method 0x85f6d155.
//
2021-06-28 06:53:50 +00:00
// Solidity: function register(string name, address owner, uint256 duration, bytes32 secret) payable returns()
2019-11-04 10:08:22 +00:00
func ( _Contract * ContractTransactor ) Register ( opts * bind . TransactOpts , name string , owner common . Address , duration * big . Int , secret [ 32 ] byte ) ( * types . Transaction , error ) {
return _Contract . contract . Transact ( opts , "register" , name , owner , duration , secret )
}
// Register is a paid mutator transaction binding the contract method 0x85f6d155.
//
2021-06-28 06:53:50 +00:00
// Solidity: function register(string name, address owner, uint256 duration, bytes32 secret) payable returns()
2019-11-04 10:08:22 +00:00
func ( _Contract * ContractSession ) Register ( name string , owner common . Address , duration * big . Int , secret [ 32 ] byte ) ( * types . Transaction , error ) {
return _Contract . Contract . Register ( & _Contract . TransactOpts , name , owner , duration , secret )
}
// Register is a paid mutator transaction binding the contract method 0x85f6d155.
//
2021-06-28 06:53:50 +00:00
// Solidity: function register(string name, address owner, uint256 duration, bytes32 secret) payable returns()
2019-11-04 10:08:22 +00:00
func ( _Contract * ContractTransactorSession ) Register ( name string , owner common . Address , duration * big . Int , secret [ 32 ] byte ) ( * types . Transaction , error ) {
return _Contract . Contract . Register ( & _Contract . TransactOpts , name , owner , duration , secret )
}
// Renew is a paid mutator transaction binding the contract method 0xacf1a841.
//
2021-06-28 06:53:50 +00:00
// Solidity: function renew(string name, uint256 duration) payable returns()
2019-11-04 10:08:22 +00:00
func ( _Contract * ContractTransactor ) Renew ( opts * bind . TransactOpts , name string , duration * big . Int ) ( * types . Transaction , error ) {
return _Contract . contract . Transact ( opts , "renew" , name , duration )
}
// Renew is a paid mutator transaction binding the contract method 0xacf1a841.
//
2021-06-28 06:53:50 +00:00
// Solidity: function renew(string name, uint256 duration) payable returns()
2019-11-04 10:08:22 +00:00
func ( _Contract * ContractSession ) Renew ( name string , duration * big . Int ) ( * types . Transaction , error ) {
return _Contract . Contract . Renew ( & _Contract . TransactOpts , name , duration )
}
// Renew is a paid mutator transaction binding the contract method 0xacf1a841.
//
2021-06-28 06:53:50 +00:00
// Solidity: function renew(string name, uint256 duration) payable returns()
2019-11-04 10:08:22 +00:00
func ( _Contract * ContractTransactorSession ) Renew ( name string , duration * big . Int ) ( * types . Transaction , error ) {
return _Contract . Contract . Renew ( & _Contract . TransactOpts , name , duration )
}
// RenounceOwnership is a paid mutator transaction binding the contract method 0x715018a6.
//
// Solidity: function renounceOwnership() returns()
func ( _Contract * ContractTransactor ) RenounceOwnership ( opts * bind . TransactOpts ) ( * types . Transaction , error ) {
return _Contract . contract . Transact ( opts , "renounceOwnership" )
}
// RenounceOwnership is a paid mutator transaction binding the contract method 0x715018a6.
//
// Solidity: function renounceOwnership() returns()
func ( _Contract * ContractSession ) RenounceOwnership ( ) ( * types . Transaction , error ) {
return _Contract . Contract . RenounceOwnership ( & _Contract . TransactOpts )
}
// RenounceOwnership is a paid mutator transaction binding the contract method 0x715018a6.
//
// Solidity: function renounceOwnership() returns()
func ( _Contract * ContractTransactorSession ) RenounceOwnership ( ) ( * types . Transaction , error ) {
return _Contract . Contract . RenounceOwnership ( & _Contract . TransactOpts )
}
// SetCommitmentAges is a paid mutator transaction binding the contract method 0x7e324479.
//
// Solidity: function setCommitmentAges(uint256 _minCommitmentAge, uint256 _maxCommitmentAge) returns()
func ( _Contract * ContractTransactor ) SetCommitmentAges ( opts * bind . TransactOpts , _minCommitmentAge * big . Int , _maxCommitmentAge * big . Int ) ( * types . Transaction , error ) {
return _Contract . contract . Transact ( opts , "setCommitmentAges" , _minCommitmentAge , _maxCommitmentAge )
}
// SetCommitmentAges is a paid mutator transaction binding the contract method 0x7e324479.
//
// Solidity: function setCommitmentAges(uint256 _minCommitmentAge, uint256 _maxCommitmentAge) returns()
func ( _Contract * ContractSession ) SetCommitmentAges ( _minCommitmentAge * big . Int , _maxCommitmentAge * big . Int ) ( * types . Transaction , error ) {
return _Contract . Contract . SetCommitmentAges ( & _Contract . TransactOpts , _minCommitmentAge , _maxCommitmentAge )
}
// SetCommitmentAges is a paid mutator transaction binding the contract method 0x7e324479.
//
// Solidity: function setCommitmentAges(uint256 _minCommitmentAge, uint256 _maxCommitmentAge) returns()
func ( _Contract * ContractTransactorSession ) SetCommitmentAges ( _minCommitmentAge * big . Int , _maxCommitmentAge * big . Int ) ( * types . Transaction , error ) {
return _Contract . Contract . SetCommitmentAges ( & _Contract . TransactOpts , _minCommitmentAge , _maxCommitmentAge )
}
// SetPriceOracle is a paid mutator transaction binding the contract method 0x530e784f.
//
// Solidity: function setPriceOracle(address _prices) returns()
func ( _Contract * ContractTransactor ) SetPriceOracle ( opts * bind . TransactOpts , _prices common . Address ) ( * types . Transaction , error ) {
return _Contract . contract . Transact ( opts , "setPriceOracle" , _prices )
}
// SetPriceOracle is a paid mutator transaction binding the contract method 0x530e784f.
//
// Solidity: function setPriceOracle(address _prices) returns()
func ( _Contract * ContractSession ) SetPriceOracle ( _prices common . Address ) ( * types . Transaction , error ) {
return _Contract . Contract . SetPriceOracle ( & _Contract . TransactOpts , _prices )
}
// SetPriceOracle is a paid mutator transaction binding the contract method 0x530e784f.
//
// Solidity: function setPriceOracle(address _prices) returns()
func ( _Contract * ContractTransactorSession ) SetPriceOracle ( _prices common . Address ) ( * types . Transaction , error ) {
return _Contract . Contract . SetPriceOracle ( & _Contract . TransactOpts , _prices )
}
// TransferOwnership is a paid mutator transaction binding the contract method 0xf2fde38b.
//
// Solidity: function transferOwnership(address newOwner) returns()
func ( _Contract * ContractTransactor ) TransferOwnership ( opts * bind . TransactOpts , newOwner common . Address ) ( * types . Transaction , error ) {
return _Contract . contract . Transact ( opts , "transferOwnership" , newOwner )
}
// TransferOwnership is a paid mutator transaction binding the contract method 0xf2fde38b.
//
// Solidity: function transferOwnership(address newOwner) returns()
func ( _Contract * ContractSession ) TransferOwnership ( newOwner common . Address ) ( * types . Transaction , error ) {
return _Contract . Contract . TransferOwnership ( & _Contract . TransactOpts , newOwner )
}
// TransferOwnership is a paid mutator transaction binding the contract method 0xf2fde38b.
//
// Solidity: function transferOwnership(address newOwner) returns()
func ( _Contract * ContractTransactorSession ) TransferOwnership ( newOwner common . Address ) ( * types . Transaction , error ) {
return _Contract . Contract . TransferOwnership ( & _Contract . TransactOpts , newOwner )
}
// Withdraw is a paid mutator transaction binding the contract method 0x3ccfd60b.
//
// Solidity: function withdraw() returns()
func ( _Contract * ContractTransactor ) Withdraw ( opts * bind . TransactOpts ) ( * types . Transaction , error ) {
return _Contract . contract . Transact ( opts , "withdraw" )
}
// Withdraw is a paid mutator transaction binding the contract method 0x3ccfd60b.
//
// Solidity: function withdraw() returns()
func ( _Contract * ContractSession ) Withdraw ( ) ( * types . Transaction , error ) {
return _Contract . Contract . Withdraw ( & _Contract . TransactOpts )
}
// Withdraw is a paid mutator transaction binding the contract method 0x3ccfd60b.
//
// Solidity: function withdraw() returns()
func ( _Contract * ContractTransactorSession ) Withdraw ( ) ( * types . Transaction , error ) {
return _Contract . Contract . Withdraw ( & _Contract . TransactOpts )
}
// ContractNameRegisteredIterator is returned from FilterNameRegistered and is used to iterate over the raw logs and unpacked data for NameRegistered events raised by the Contract contract.
type ContractNameRegisteredIterator struct {
Event * ContractNameRegistered // Event containing the contract specifics and raw log
contract * bind . BoundContract // Generic contract to use for unpacking event data
event string // Event name to use for unpacking event data
logs chan types . Log // Log channel receiving the found contract events
sub ethereum . Subscription // Subscription for errors, completion and termination
done bool // Whether the subscription completed delivering logs
fail error // Occurred error to stop iteration
}
// 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.
func ( it * ContractNameRegisteredIterator ) Next ( ) bool {
// If the iterator failed, stop iterating
if it . fail != nil {
return false
}
// If the iterator completed, deliver directly whatever's available
if it . done {
select {
case log := <- it . logs :
it . Event = new ( ContractNameRegistered )
if err := it . contract . UnpackLog ( it . Event , it . event , log ) ; err != nil {
it . fail = err
return false
}
it . Event . Raw = log
return true
default :
return false
}
}
// Iterator still in progress, wait for either a data or an error event
select {
case log := <- it . logs :
it . Event = new ( ContractNameRegistered )
if err := it . contract . UnpackLog ( it . Event , it . event , log ) ; err != nil {
it . fail = err
return false
}
it . Event . Raw = log
return true
case err := <- it . sub . Err ( ) :
it . done = true
it . fail = err
return it . Next ( )
}
}
// Error returns any retrieval or parsing error occurred during filtering.
func ( it * ContractNameRegisteredIterator ) Error ( ) error {
return it . fail
}
// Close terminates the iteration process, releasing any pending underlying
// resources.
func ( it * ContractNameRegisteredIterator ) Close ( ) error {
it . sub . Unsubscribe ( )
return nil
}
// ContractNameRegistered represents a NameRegistered event raised by the Contract contract.
type ContractNameRegistered struct {
Name string
Label [ 32 ] byte
Owner common . Address
Cost * big . Int
Expires * big . Int
Raw types . Log // Blockchain specific contextual infos
}
// FilterNameRegistered is a free log retrieval operation binding the contract event 0xca6abbe9d7f11422cb6ca7629fbf6fe9efb1c621f71ce8f02b9f2a230097404f.
//
// Solidity: event NameRegistered(string name, bytes32 indexed label, address indexed owner, uint256 cost, uint256 expires)
func ( _Contract * ContractFilterer ) FilterNameRegistered ( opts * bind . FilterOpts , label [ ] [ 32 ] byte , owner [ ] common . Address ) ( * ContractNameRegisteredIterator , error ) {
var labelRule [ ] interface { }
for _ , labelItem := range label {
labelRule = append ( labelRule , labelItem )
}
var ownerRule [ ] interface { }
for _ , ownerItem := range owner {
ownerRule = append ( ownerRule , ownerItem )
}
logs , sub , err := _Contract . contract . FilterLogs ( opts , "NameRegistered" , labelRule , ownerRule )
if err != nil {
return nil , err
}
return & ContractNameRegisteredIterator { contract : _Contract . contract , event : "NameRegistered" , logs : logs , sub : sub } , nil
}
// WatchNameRegistered is a free log subscription operation binding the contract event 0xca6abbe9d7f11422cb6ca7629fbf6fe9efb1c621f71ce8f02b9f2a230097404f.
//
// Solidity: event NameRegistered(string name, bytes32 indexed label, address indexed owner, uint256 cost, uint256 expires)
func ( _Contract * ContractFilterer ) WatchNameRegistered ( opts * bind . WatchOpts , sink chan <- * ContractNameRegistered , label [ ] [ 32 ] byte , owner [ ] common . Address ) ( event . Subscription , error ) {
var labelRule [ ] interface { }
for _ , labelItem := range label {
labelRule = append ( labelRule , labelItem )
}
var ownerRule [ ] interface { }
for _ , ownerItem := range owner {
ownerRule = append ( ownerRule , ownerItem )
}
logs , sub , err := _Contract . contract . WatchLogs ( opts , "NameRegistered" , labelRule , ownerRule )
if err != nil {
return nil , err
}
return event . NewSubscription ( func ( quit <- chan struct { } ) error {
defer sub . Unsubscribe ( )
for {
select {
case log := <- logs :
// New log arrived, parse the event and forward to the user
event := new ( ContractNameRegistered )
if err := _Contract . contract . UnpackLog ( event , "NameRegistered" , log ) ; err != nil {
return err
}
event . Raw = log
select {
case sink <- event :
case err := <- sub . Err ( ) :
return err
case <- quit :
return nil
}
case err := <- sub . Err ( ) :
return err
case <- quit :
return nil
}
}
} ) , nil
}
2021-06-28 06:53:50 +00:00
// ParseNameRegistered is a log parse operation binding the contract event 0xca6abbe9d7f11422cb6ca7629fbf6fe9efb1c621f71ce8f02b9f2a230097404f.
//
// Solidity: event NameRegistered(string name, bytes32 indexed label, address indexed owner, uint256 cost, uint256 expires)
func ( _Contract * ContractFilterer ) ParseNameRegistered ( log types . Log ) ( * ContractNameRegistered , error ) {
event := new ( ContractNameRegistered )
if err := _Contract . contract . UnpackLog ( event , "NameRegistered" , log ) ; err != nil {
return nil , err
}
return event , nil
}
2019-11-04 10:08:22 +00:00
// ContractNameRenewedIterator is returned from FilterNameRenewed and is used to iterate over the raw logs and unpacked data for NameRenewed events raised by the Contract contract.
type ContractNameRenewedIterator struct {
Event * ContractNameRenewed // Event containing the contract specifics and raw log
contract * bind . BoundContract // Generic contract to use for unpacking event data
event string // Event name to use for unpacking event data
logs chan types . Log // Log channel receiving the found contract events
sub ethereum . Subscription // Subscription for errors, completion and termination
done bool // Whether the subscription completed delivering logs
fail error // Occurred error to stop iteration
}
// 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.
func ( it * ContractNameRenewedIterator ) Next ( ) bool {
// If the iterator failed, stop iterating
if it . fail != nil {
return false
}
// If the iterator completed, deliver directly whatever's available
if it . done {
select {
case log := <- it . logs :
it . Event = new ( ContractNameRenewed )
if err := it . contract . UnpackLog ( it . Event , it . event , log ) ; err != nil {
it . fail = err
return false
}
it . Event . Raw = log
return true
default :
return false
}
}
// Iterator still in progress, wait for either a data or an error event
select {
case log := <- it . logs :
it . Event = new ( ContractNameRenewed )
if err := it . contract . UnpackLog ( it . Event , it . event , log ) ; err != nil {
it . fail = err
return false
}
it . Event . Raw = log
return true
case err := <- it . sub . Err ( ) :
it . done = true
it . fail = err
return it . Next ( )
}
}
// Error returns any retrieval or parsing error occurred during filtering.
func ( it * ContractNameRenewedIterator ) Error ( ) error {
return it . fail
}
// Close terminates the iteration process, releasing any pending underlying
// resources.
func ( it * ContractNameRenewedIterator ) Close ( ) error {
it . sub . Unsubscribe ( )
return nil
}
// ContractNameRenewed represents a NameRenewed event raised by the Contract contract.
type ContractNameRenewed struct {
Name string
Label [ 32 ] byte
Cost * big . Int
Expires * big . Int
Raw types . Log // Blockchain specific contextual infos
}
// FilterNameRenewed is a free log retrieval operation binding the contract event 0x3da24c024582931cfaf8267d8ed24d13a82a8068d5bd337d30ec45cea4e506ae.
//
// Solidity: event NameRenewed(string name, bytes32 indexed label, uint256 cost, uint256 expires)
func ( _Contract * ContractFilterer ) FilterNameRenewed ( opts * bind . FilterOpts , label [ ] [ 32 ] byte ) ( * ContractNameRenewedIterator , error ) {
var labelRule [ ] interface { }
for _ , labelItem := range label {
labelRule = append ( labelRule , labelItem )
}
logs , sub , err := _Contract . contract . FilterLogs ( opts , "NameRenewed" , labelRule )
if err != nil {
return nil , err
}
return & ContractNameRenewedIterator { contract : _Contract . contract , event : "NameRenewed" , logs : logs , sub : sub } , nil
}
// WatchNameRenewed is a free log subscription operation binding the contract event 0x3da24c024582931cfaf8267d8ed24d13a82a8068d5bd337d30ec45cea4e506ae.
//
// Solidity: event NameRenewed(string name, bytes32 indexed label, uint256 cost, uint256 expires)
func ( _Contract * ContractFilterer ) WatchNameRenewed ( opts * bind . WatchOpts , sink chan <- * ContractNameRenewed , label [ ] [ 32 ] byte ) ( event . Subscription , error ) {
var labelRule [ ] interface { }
for _ , labelItem := range label {
labelRule = append ( labelRule , labelItem )
}
logs , sub , err := _Contract . contract . WatchLogs ( opts , "NameRenewed" , labelRule )
if err != nil {
return nil , err
}
return event . NewSubscription ( func ( quit <- chan struct { } ) error {
defer sub . Unsubscribe ( )
for {
select {
case log := <- logs :
// New log arrived, parse the event and forward to the user
event := new ( ContractNameRenewed )
if err := _Contract . contract . UnpackLog ( event , "NameRenewed" , log ) ; err != nil {
return err
}
event . Raw = log
select {
case sink <- event :
case err := <- sub . Err ( ) :
return err
case <- quit :
return nil
}
case err := <- sub . Err ( ) :
return err
case <- quit :
return nil
}
}
} ) , nil
}
2021-06-28 06:53:50 +00:00
// ParseNameRenewed is a log parse operation binding the contract event 0x3da24c024582931cfaf8267d8ed24d13a82a8068d5bd337d30ec45cea4e506ae.
//
// Solidity: event NameRenewed(string name, bytes32 indexed label, uint256 cost, uint256 expires)
func ( _Contract * ContractFilterer ) ParseNameRenewed ( log types . Log ) ( * ContractNameRenewed , error ) {
event := new ( ContractNameRenewed )
if err := _Contract . contract . UnpackLog ( event , "NameRenewed" , log ) ; err != nil {
return nil , err
}
return event , nil
}
2019-11-04 10:08:22 +00:00
// ContractNewPriceOracleIterator is returned from FilterNewPriceOracle and is used to iterate over the raw logs and unpacked data for NewPriceOracle events raised by the Contract contract.
type ContractNewPriceOracleIterator struct {
Event * ContractNewPriceOracle // Event containing the contract specifics and raw log
contract * bind . BoundContract // Generic contract to use for unpacking event data
event string // Event name to use for unpacking event data
logs chan types . Log // Log channel receiving the found contract events
sub ethereum . Subscription // Subscription for errors, completion and termination
done bool // Whether the subscription completed delivering logs
fail error // Occurred error to stop iteration
}
// 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.
func ( it * ContractNewPriceOracleIterator ) Next ( ) bool {
// If the iterator failed, stop iterating
if it . fail != nil {
return false
}
// If the iterator completed, deliver directly whatever's available
if it . done {
select {
case log := <- it . logs :
it . Event = new ( ContractNewPriceOracle )
if err := it . contract . UnpackLog ( it . Event , it . event , log ) ; err != nil {
it . fail = err
return false
}
it . Event . Raw = log
return true
default :
return false
}
}
// Iterator still in progress, wait for either a data or an error event
select {
case log := <- it . logs :
it . Event = new ( ContractNewPriceOracle )
if err := it . contract . UnpackLog ( it . Event , it . event , log ) ; err != nil {
it . fail = err
return false
}
it . Event . Raw = log
return true
case err := <- it . sub . Err ( ) :
it . done = true
it . fail = err
return it . Next ( )
}
}
// Error returns any retrieval or parsing error occurred during filtering.
func ( it * ContractNewPriceOracleIterator ) Error ( ) error {
return it . fail
}
// Close terminates the iteration process, releasing any pending underlying
// resources.
func ( it * ContractNewPriceOracleIterator ) Close ( ) error {
it . sub . Unsubscribe ( )
return nil
}
// ContractNewPriceOracle represents a NewPriceOracle event raised by the Contract contract.
type ContractNewPriceOracle struct {
Oracle common . Address
Raw types . Log // Blockchain specific contextual infos
}
// FilterNewPriceOracle is a free log retrieval operation binding the contract event 0xf261845a790fe29bbd6631e2ca4a5bdc83e6eed7c3271d9590d97287e00e9123.
//
// Solidity: event NewPriceOracle(address indexed oracle)
func ( _Contract * ContractFilterer ) FilterNewPriceOracle ( opts * bind . FilterOpts , oracle [ ] common . Address ) ( * ContractNewPriceOracleIterator , error ) {
var oracleRule [ ] interface { }
for _ , oracleItem := range oracle {
oracleRule = append ( oracleRule , oracleItem )
}
logs , sub , err := _Contract . contract . FilterLogs ( opts , "NewPriceOracle" , oracleRule )
if err != nil {
return nil , err
}
return & ContractNewPriceOracleIterator { contract : _Contract . contract , event : "NewPriceOracle" , logs : logs , sub : sub } , nil
}
// WatchNewPriceOracle is a free log subscription operation binding the contract event 0xf261845a790fe29bbd6631e2ca4a5bdc83e6eed7c3271d9590d97287e00e9123.
//
// Solidity: event NewPriceOracle(address indexed oracle)
func ( _Contract * ContractFilterer ) WatchNewPriceOracle ( opts * bind . WatchOpts , sink chan <- * ContractNewPriceOracle , oracle [ ] common . Address ) ( event . Subscription , error ) {
var oracleRule [ ] interface { }
for _ , oracleItem := range oracle {
oracleRule = append ( oracleRule , oracleItem )
}
logs , sub , err := _Contract . contract . WatchLogs ( opts , "NewPriceOracle" , oracleRule )
if err != nil {
return nil , err
}
return event . NewSubscription ( func ( quit <- chan struct { } ) error {
defer sub . Unsubscribe ( )
for {
select {
case log := <- logs :
// New log arrived, parse the event and forward to the user
event := new ( ContractNewPriceOracle )
if err := _Contract . contract . UnpackLog ( event , "NewPriceOracle" , log ) ; err != nil {
return err
}
event . Raw = log
select {
case sink <- event :
case err := <- sub . Err ( ) :
return err
case <- quit :
return nil
}
case err := <- sub . Err ( ) :
return err
case <- quit :
return nil
}
}
} ) , nil
}
2021-06-28 06:53:50 +00:00
// ParseNewPriceOracle is a log parse operation binding the contract event 0xf261845a790fe29bbd6631e2ca4a5bdc83e6eed7c3271d9590d97287e00e9123.
//
// Solidity: event NewPriceOracle(address indexed oracle)
func ( _Contract * ContractFilterer ) ParseNewPriceOracle ( log types . Log ) ( * ContractNewPriceOracle , error ) {
event := new ( ContractNewPriceOracle )
if err := _Contract . contract . UnpackLog ( event , "NewPriceOracle" , log ) ; err != nil {
return nil , err
}
return event , nil
}
2019-11-04 10:08:22 +00:00
// ContractOwnershipTransferredIterator is returned from FilterOwnershipTransferred and is used to iterate over the raw logs and unpacked data for OwnershipTransferred events raised by the Contract contract.
type ContractOwnershipTransferredIterator struct {
Event * ContractOwnershipTransferred // Event containing the contract specifics and raw log
contract * bind . BoundContract // Generic contract to use for unpacking event data
event string // Event name to use for unpacking event data
logs chan types . Log // Log channel receiving the found contract events
sub ethereum . Subscription // Subscription for errors, completion and termination
done bool // Whether the subscription completed delivering logs
fail error // Occurred error to stop iteration
}
// 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.
func ( it * ContractOwnershipTransferredIterator ) Next ( ) bool {
// If the iterator failed, stop iterating
if it . fail != nil {
return false
}
// If the iterator completed, deliver directly whatever's available
if it . done {
select {
case log := <- it . logs :
it . Event = new ( ContractOwnershipTransferred )
if err := it . contract . UnpackLog ( it . Event , it . event , log ) ; err != nil {
it . fail = err
return false
}
it . Event . Raw = log
return true
default :
return false
}
}
// Iterator still in progress, wait for either a data or an error event
select {
case log := <- it . logs :
it . Event = new ( ContractOwnershipTransferred )
if err := it . contract . UnpackLog ( it . Event , it . event , log ) ; err != nil {
it . fail = err
return false
}
it . Event . Raw = log
return true
case err := <- it . sub . Err ( ) :
it . done = true
it . fail = err
return it . Next ( )
}
}
// Error returns any retrieval or parsing error occurred during filtering.
func ( it * ContractOwnershipTransferredIterator ) Error ( ) error {
return it . fail
}
// Close terminates the iteration process, releasing any pending underlying
// resources.
func ( it * ContractOwnershipTransferredIterator ) Close ( ) error {
it . sub . Unsubscribe ( )
return nil
}
// ContractOwnershipTransferred represents a OwnershipTransferred event raised by the Contract contract.
type ContractOwnershipTransferred struct {
PreviousOwner common . Address
NewOwner common . Address
Raw types . Log // Blockchain specific contextual infos
}
// FilterOwnershipTransferred is a free log retrieval operation binding the contract event 0x8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0.
//
// Solidity: event OwnershipTransferred(address indexed previousOwner, address indexed newOwner)
func ( _Contract * ContractFilterer ) FilterOwnershipTransferred ( opts * bind . FilterOpts , previousOwner [ ] common . Address , newOwner [ ] common . Address ) ( * ContractOwnershipTransferredIterator , error ) {
var previousOwnerRule [ ] interface { }
for _ , previousOwnerItem := range previousOwner {
previousOwnerRule = append ( previousOwnerRule , previousOwnerItem )
}
var newOwnerRule [ ] interface { }
for _ , newOwnerItem := range newOwner {
newOwnerRule = append ( newOwnerRule , newOwnerItem )
}
logs , sub , err := _Contract . contract . FilterLogs ( opts , "OwnershipTransferred" , previousOwnerRule , newOwnerRule )
if err != nil {
return nil , err
}
return & ContractOwnershipTransferredIterator { contract : _Contract . contract , event : "OwnershipTransferred" , logs : logs , sub : sub } , nil
}
// WatchOwnershipTransferred is a free log subscription operation binding the contract event 0x8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0.
//
// Solidity: event OwnershipTransferred(address indexed previousOwner, address indexed newOwner)
func ( _Contract * ContractFilterer ) WatchOwnershipTransferred ( opts * bind . WatchOpts , sink chan <- * ContractOwnershipTransferred , previousOwner [ ] common . Address , newOwner [ ] common . Address ) ( event . Subscription , error ) {
var previousOwnerRule [ ] interface { }
for _ , previousOwnerItem := range previousOwner {
previousOwnerRule = append ( previousOwnerRule , previousOwnerItem )
}
var newOwnerRule [ ] interface { }
for _ , newOwnerItem := range newOwner {
newOwnerRule = append ( newOwnerRule , newOwnerItem )
}
logs , sub , err := _Contract . contract . WatchLogs ( opts , "OwnershipTransferred" , previousOwnerRule , newOwnerRule )
if err != nil {
return nil , err
}
return event . NewSubscription ( func ( quit <- chan struct { } ) error {
defer sub . Unsubscribe ( )
for {
select {
case log := <- logs :
// New log arrived, parse the event and forward to the user
event := new ( ContractOwnershipTransferred )
if err := _Contract . contract . UnpackLog ( event , "OwnershipTransferred" , log ) ; err != nil {
return err
}
event . Raw = log
select {
case sink <- event :
case err := <- sub . Err ( ) :
return err
case <- quit :
return nil
}
case err := <- sub . Err ( ) :
return err
case <- quit :
return nil
}
}
} ) , nil
}
2021-06-28 06:53:50 +00:00
// ParseOwnershipTransferred is a log parse operation binding the contract event 0x8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0.
//
// Solidity: event OwnershipTransferred(address indexed previousOwner, address indexed newOwner)
func ( _Contract * ContractFilterer ) ParseOwnershipTransferred ( log types . Log ) ( * ContractOwnershipTransferred , error ) {
event := new ( ContractOwnershipTransferred )
if err := _Contract . contract . UnpackLog ( event , "OwnershipTransferred" , log ) ; err != nil {
return nil , err
}
return event , nil
}