github.com/0xPolygon/supernets2-node@v0.0.0-20230711153321-2fe574524eaa/test/contracts/bin/uniswap/v2/core/UniswapV2ERC20/UniswapV2ERC20.go (about)

     1  // Code generated - DO NOT EDIT.
     2  // This file is a generated binding and any manual changes will be lost.
     3  
     4  package UniswapV2ERC20
     5  
     6  import (
     7  	"errors"
     8  	"math/big"
     9  	"strings"
    10  
    11  	ethereum "github.com/ethereum/go-ethereum"
    12  	"github.com/ethereum/go-ethereum/accounts/abi"
    13  	"github.com/ethereum/go-ethereum/accounts/abi/bind"
    14  	"github.com/ethereum/go-ethereum/common"
    15  	"github.com/ethereum/go-ethereum/core/types"
    16  	"github.com/ethereum/go-ethereum/event"
    17  )
    18  
    19  // Reference imports to suppress errors if they are not otherwise used.
    20  var (
    21  	_ = errors.New
    22  	_ = big.NewInt
    23  	_ = strings.NewReader
    24  	_ = ethereum.NotFound
    25  	_ = bind.Bind
    26  	_ = common.Big1
    27  	_ = types.BloomLookup
    28  	_ = event.NewSubscription
    29  	_ = abi.ConvertType
    30  )
    31  
    32  // UniswapV2ERC20MetaData contains all meta data concerning the UniswapV2ERC20 contract.
    33  var UniswapV2ERC20MetaData = &bind.MetaData{
    34  	ABI: "[{\"inputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"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\"},{\"constant\":true,\"inputs\":[],\"name\":\"DOMAIN_SEPARATOR\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"PERMIT_TYPEHASH\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"name\":\"allowance\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"internalType\":\"address\",\"name\":\"spender\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"approve\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"name\":\"balanceOf\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"decimals\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"\",\"type\":\"uint8\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"name\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"name\":\"nonces\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"spender\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"deadline\",\"type\":\"uint256\"},{\"internalType\":\"uint8\",\"name\":\"v\",\"type\":\"uint8\"},{\"internalType\":\"bytes32\",\"name\":\"r\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"s\",\"type\":\"bytes32\"}],\"name\":\"permit\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"symbol\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"totalSupply\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"transfer\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":false,\"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\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]",
    35  	Bin: "0x608060405234801561001057600080fd5b50604051469080605261096c8239604080519182900360520182208282018252600a8352692ab734b9bbb0b8102b1960b11b6020938401528151808301835260018152603160f81b908401528151808401919091527fbfcc8ef98ffbf7b6c3fec7bf5185b566b9863e35a9d83acd49ad6824b5969738818301527fc89efdaa54c0f20c7adf612882df0950f5a951637e0307cdcb4c672f298b8bc6606082015260808101949094523060a0808601919091528151808603909101815260c0909401905282519201919091206003555061087e806100ee6000396000f3fe608060405234801561001057600080fd5b50600436106100cf5760003560e01c80633644e5151161008c57806395d89b411161006657806395d89b411461025b578063a9059cbb14610263578063d505accf1461028f578063dd62ed3e146102e2576100cf565b80633644e5151461020757806370a082311461020f5780637ecebe0014610235576100cf565b806306fdde03146100d4578063095ea7b31461015157806318160ddd1461019157806323b872dd146101ab57806330adf81f146101e1578063313ce567146101e9575b600080fd5b6100dc610310565b6040805160208082528351818301528351919283929083019185019080838360005b838110156101165781810151838201526020016100fe565b50505050905090810190601f1680156101435780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b61017d6004803603604081101561016757600080fd5b506001600160a01b038135169060200135610336565b604080519115158252519081900360200190f35b61019961034d565b60408051918252519081900360200190f35b61017d600480360360608110156101c157600080fd5b506001600160a01b03813581169160208101359091169060400135610353565b6101996103ed565b6101f1610411565b6040805160ff9092168252519081900360200190f35b610199610416565b6101996004803603602081101561022557600080fd5b50356001600160a01b031661041c565b6101996004803603602081101561024b57600080fd5b50356001600160a01b031661042e565b6100dc610440565b61017d6004803603604081101561027957600080fd5b506001600160a01b038135169060200135610462565b6102e0600480360360e08110156102a557600080fd5b506001600160a01b03813581169160208101359091169060408101359060608101359060ff6080820135169060a08101359060c0013561046f565b005b610199600480360360408110156102f857600080fd5b506001600160a01b0381358116916020013516610671565b6040518060400160405280600a8152602001692ab734b9bbb0b8102b1960b11b81525081565b600061034333848461068e565b5060015b92915050565b60005481565b6001600160a01b0383166000908152600260209081526040808320338452909152812054600019146103d8576001600160a01b03841660009081526002602090815260408083203384529091529020546103b3908363ffffffff6106f016565b6001600160a01b03851660009081526002602090815260408083203384529091529020555b6103e3848484610740565b5060019392505050565b7f6e71edae12b1b97f4d1f60370fef10105fa2faae0126114a169c64845d6126c981565b601281565b60035481565b60016020526000908152604090205481565b60046020526000908152604090205481565b604051806040016040528060068152602001652aa72496ab1960d11b81525081565b6000610343338484610740565b428410156104b9576040805162461bcd60e51b8152602060048201526012602482015271155b9a5cddd85c158c8e881156141254915160721b604482015290519081900360640190fd5b6003546001600160a01b0380891660008181526004602090815260408083208054600180820190925582517f6e71edae12b1b97f4d1f60370fef10105fa2faae0126114a169c64845d6126c98186015280840196909652958d166060860152608085018c905260a085019590955260c08085018b90528151808603909101815260e08501825280519083012061190160f01b6101008601526101028501969096526101228085019690965280518085039096018652610142840180825286519683019690962095839052610162840180825286905260ff89166101828501526101a284018890526101c28401879052519193926101e280820193601f1981019281900390910190855afa1580156105d4573d6000803e3d6000fd5b5050604051601f1901519150506001600160a01b0381161580159061060a5750886001600160a01b0316816001600160a01b0316145b61065b576040805162461bcd60e51b815260206004820152601c60248201527f556e697377617056323a20494e56414c49445f5349474e415455524500000000604482015290519081900360640190fd5b61066689898961068e565b505050505050505050565b600260209081526000928352604080842090915290825290205481565b6001600160a01b03808416600081815260026020908152604080832094871680845294825291829020859055815185815291517f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b9259281900390910190a3505050565b80820382811115610347576040805162461bcd60e51b815260206004820152601560248201527464732d6d6174682d7375622d756e646572666c6f7760581b604482015290519081900360640190fd5b6001600160a01b038316600090815260016020526040902054610769908263ffffffff6106f016565b6001600160a01b03808516600090815260016020526040808220939093559084168152205461079e908263ffffffff6107fa16565b6001600160a01b0380841660008181526001602090815260409182902094909455805185815290519193928716927fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef92918290030190a3505050565b80820182811015610347576040805162461bcd60e51b815260206004820152601460248201527364732d6d6174682d6164642d6f766572666c6f7760601b604482015290519081900360640190fdfea265627a7a72315820248061664cd6b2ec57592c9004973d95ca4473e9ac456dc3769d651599f49db464736f6c63430005100032454950373132446f6d61696e28737472696e67206e616d652c737472696e672076657273696f6e2c75696e7432353620636861696e49642c6164647265737320766572696679696e67436f6e747261637429",
    36  }
    37  
    38  // UniswapV2ERC20ABI is the input ABI used to generate the binding from.
    39  // Deprecated: Use UniswapV2ERC20MetaData.ABI instead.
    40  var UniswapV2ERC20ABI = UniswapV2ERC20MetaData.ABI
    41  
    42  // UniswapV2ERC20Bin is the compiled bytecode used for deploying new contracts.
    43  // Deprecated: Use UniswapV2ERC20MetaData.Bin instead.
    44  var UniswapV2ERC20Bin = UniswapV2ERC20MetaData.Bin
    45  
    46  // DeployUniswapV2ERC20 deploys a new Ethereum contract, binding an instance of UniswapV2ERC20 to it.
    47  func DeployUniswapV2ERC20(auth *bind.TransactOpts, backend bind.ContractBackend) (common.Address, *types.Transaction, *UniswapV2ERC20, error) {
    48  	parsed, err := UniswapV2ERC20MetaData.GetAbi()
    49  	if err != nil {
    50  		return common.Address{}, nil, nil, err
    51  	}
    52  	if parsed == nil {
    53  		return common.Address{}, nil, nil, errors.New("GetABI returned nil")
    54  	}
    55  
    56  	address, tx, contract, err := bind.DeployContract(auth, *parsed, common.FromHex(UniswapV2ERC20Bin), backend)
    57  	if err != nil {
    58  		return common.Address{}, nil, nil, err
    59  	}
    60  	return address, tx, &UniswapV2ERC20{UniswapV2ERC20Caller: UniswapV2ERC20Caller{contract: contract}, UniswapV2ERC20Transactor: UniswapV2ERC20Transactor{contract: contract}, UniswapV2ERC20Filterer: UniswapV2ERC20Filterer{contract: contract}}, nil
    61  }
    62  
    63  // UniswapV2ERC20 is an auto generated Go binding around an Ethereum contract.
    64  type UniswapV2ERC20 struct {
    65  	UniswapV2ERC20Caller     // Read-only binding to the contract
    66  	UniswapV2ERC20Transactor // Write-only binding to the contract
    67  	UniswapV2ERC20Filterer   // Log filterer for contract events
    68  }
    69  
    70  // UniswapV2ERC20Caller is an auto generated read-only Go binding around an Ethereum contract.
    71  type UniswapV2ERC20Caller struct {
    72  	contract *bind.BoundContract // Generic contract wrapper for the low level calls
    73  }
    74  
    75  // UniswapV2ERC20Transactor is an auto generated write-only Go binding around an Ethereum contract.
    76  type UniswapV2ERC20Transactor struct {
    77  	contract *bind.BoundContract // Generic contract wrapper for the low level calls
    78  }
    79  
    80  // UniswapV2ERC20Filterer is an auto generated log filtering Go binding around an Ethereum contract events.
    81  type UniswapV2ERC20Filterer struct {
    82  	contract *bind.BoundContract // Generic contract wrapper for the low level calls
    83  }
    84  
    85  // UniswapV2ERC20Session is an auto generated Go binding around an Ethereum contract,
    86  // with pre-set call and transact options.
    87  type UniswapV2ERC20Session struct {
    88  	Contract     *UniswapV2ERC20   // Generic contract binding to set the session for
    89  	CallOpts     bind.CallOpts     // Call options to use throughout this session
    90  	TransactOpts bind.TransactOpts // Transaction auth options to use throughout this session
    91  }
    92  
    93  // UniswapV2ERC20CallerSession is an auto generated read-only Go binding around an Ethereum contract,
    94  // with pre-set call options.
    95  type UniswapV2ERC20CallerSession struct {
    96  	Contract *UniswapV2ERC20Caller // Generic contract caller binding to set the session for
    97  	CallOpts bind.CallOpts         // Call options to use throughout this session
    98  }
    99  
   100  // UniswapV2ERC20TransactorSession is an auto generated write-only Go binding around an Ethereum contract,
   101  // with pre-set transact options.
   102  type UniswapV2ERC20TransactorSession struct {
   103  	Contract     *UniswapV2ERC20Transactor // Generic contract transactor binding to set the session for
   104  	TransactOpts bind.TransactOpts         // Transaction auth options to use throughout this session
   105  }
   106  
   107  // UniswapV2ERC20Raw is an auto generated low-level Go binding around an Ethereum contract.
   108  type UniswapV2ERC20Raw struct {
   109  	Contract *UniswapV2ERC20 // Generic contract binding to access the raw methods on
   110  }
   111  
   112  // UniswapV2ERC20CallerRaw is an auto generated low-level read-only Go binding around an Ethereum contract.
   113  type UniswapV2ERC20CallerRaw struct {
   114  	Contract *UniswapV2ERC20Caller // Generic read-only contract binding to access the raw methods on
   115  }
   116  
   117  // UniswapV2ERC20TransactorRaw is an auto generated low-level write-only Go binding around an Ethereum contract.
   118  type UniswapV2ERC20TransactorRaw struct {
   119  	Contract *UniswapV2ERC20Transactor // Generic write-only contract binding to access the raw methods on
   120  }
   121  
   122  // NewUniswapV2ERC20 creates a new instance of UniswapV2ERC20, bound to a specific deployed contract.
   123  func NewUniswapV2ERC20(address common.Address, backend bind.ContractBackend) (*UniswapV2ERC20, error) {
   124  	contract, err := bindUniswapV2ERC20(address, backend, backend, backend)
   125  	if err != nil {
   126  		return nil, err
   127  	}
   128  	return &UniswapV2ERC20{UniswapV2ERC20Caller: UniswapV2ERC20Caller{contract: contract}, UniswapV2ERC20Transactor: UniswapV2ERC20Transactor{contract: contract}, UniswapV2ERC20Filterer: UniswapV2ERC20Filterer{contract: contract}}, nil
   129  }
   130  
   131  // NewUniswapV2ERC20Caller creates a new read-only instance of UniswapV2ERC20, bound to a specific deployed contract.
   132  func NewUniswapV2ERC20Caller(address common.Address, caller bind.ContractCaller) (*UniswapV2ERC20Caller, error) {
   133  	contract, err := bindUniswapV2ERC20(address, caller, nil, nil)
   134  	if err != nil {
   135  		return nil, err
   136  	}
   137  	return &UniswapV2ERC20Caller{contract: contract}, nil
   138  }
   139  
   140  // NewUniswapV2ERC20Transactor creates a new write-only instance of UniswapV2ERC20, bound to a specific deployed contract.
   141  func NewUniswapV2ERC20Transactor(address common.Address, transactor bind.ContractTransactor) (*UniswapV2ERC20Transactor, error) {
   142  	contract, err := bindUniswapV2ERC20(address, nil, transactor, nil)
   143  	if err != nil {
   144  		return nil, err
   145  	}
   146  	return &UniswapV2ERC20Transactor{contract: contract}, nil
   147  }
   148  
   149  // NewUniswapV2ERC20Filterer creates a new log filterer instance of UniswapV2ERC20, bound to a specific deployed contract.
   150  func NewUniswapV2ERC20Filterer(address common.Address, filterer bind.ContractFilterer) (*UniswapV2ERC20Filterer, error) {
   151  	contract, err := bindUniswapV2ERC20(address, nil, nil, filterer)
   152  	if err != nil {
   153  		return nil, err
   154  	}
   155  	return &UniswapV2ERC20Filterer{contract: contract}, nil
   156  }
   157  
   158  // bindUniswapV2ERC20 binds a generic wrapper to an already deployed contract.
   159  func bindUniswapV2ERC20(address common.Address, caller bind.ContractCaller, transactor bind.ContractTransactor, filterer bind.ContractFilterer) (*bind.BoundContract, error) {
   160  	parsed, err := UniswapV2ERC20MetaData.GetAbi()
   161  	if err != nil {
   162  		return nil, err
   163  	}
   164  	return bind.NewBoundContract(address, *parsed, caller, transactor, filterer), nil
   165  }
   166  
   167  // Call invokes the (constant) contract method with params as input values and
   168  // sets the output to result. The result type might be a single field for simple
   169  // returns, a slice of interfaces for anonymous returns and a struct for named
   170  // returns.
   171  func (_UniswapV2ERC20 *UniswapV2ERC20Raw) Call(opts *bind.CallOpts, result *[]interface{}, method string, params ...interface{}) error {
   172  	return _UniswapV2ERC20.Contract.UniswapV2ERC20Caller.contract.Call(opts, result, method, params...)
   173  }
   174  
   175  // Transfer initiates a plain transaction to move funds to the contract, calling
   176  // its default method if one is available.
   177  func (_UniswapV2ERC20 *UniswapV2ERC20Raw) Transfer(opts *bind.TransactOpts) (*types.Transaction, error) {
   178  	return _UniswapV2ERC20.Contract.UniswapV2ERC20Transactor.contract.Transfer(opts)
   179  }
   180  
   181  // Transact invokes the (paid) contract method with params as input values.
   182  func (_UniswapV2ERC20 *UniswapV2ERC20Raw) Transact(opts *bind.TransactOpts, method string, params ...interface{}) (*types.Transaction, error) {
   183  	return _UniswapV2ERC20.Contract.UniswapV2ERC20Transactor.contract.Transact(opts, method, params...)
   184  }
   185  
   186  // Call invokes the (constant) contract method with params as input values and
   187  // sets the output to result. The result type might be a single field for simple
   188  // returns, a slice of interfaces for anonymous returns and a struct for named
   189  // returns.
   190  func (_UniswapV2ERC20 *UniswapV2ERC20CallerRaw) Call(opts *bind.CallOpts, result *[]interface{}, method string, params ...interface{}) error {
   191  	return _UniswapV2ERC20.Contract.contract.Call(opts, result, method, params...)
   192  }
   193  
   194  // Transfer initiates a plain transaction to move funds to the contract, calling
   195  // its default method if one is available.
   196  func (_UniswapV2ERC20 *UniswapV2ERC20TransactorRaw) Transfer(opts *bind.TransactOpts) (*types.Transaction, error) {
   197  	return _UniswapV2ERC20.Contract.contract.Transfer(opts)
   198  }
   199  
   200  // Transact invokes the (paid) contract method with params as input values.
   201  func (_UniswapV2ERC20 *UniswapV2ERC20TransactorRaw) Transact(opts *bind.TransactOpts, method string, params ...interface{}) (*types.Transaction, error) {
   202  	return _UniswapV2ERC20.Contract.contract.Transact(opts, method, params...)
   203  }
   204  
   205  // DOMAINSEPARATOR is a free data retrieval call binding the contract method 0x3644e515.
   206  //
   207  // Solidity: function DOMAIN_SEPARATOR() view returns(bytes32)
   208  func (_UniswapV2ERC20 *UniswapV2ERC20Caller) DOMAINSEPARATOR(opts *bind.CallOpts) ([32]byte, error) {
   209  	var out []interface{}
   210  	err := _UniswapV2ERC20.contract.Call(opts, &out, "DOMAIN_SEPARATOR")
   211  
   212  	if err != nil {
   213  		return *new([32]byte), err
   214  	}
   215  
   216  	out0 := *abi.ConvertType(out[0], new([32]byte)).(*[32]byte)
   217  
   218  	return out0, err
   219  
   220  }
   221  
   222  // DOMAINSEPARATOR is a free data retrieval call binding the contract method 0x3644e515.
   223  //
   224  // Solidity: function DOMAIN_SEPARATOR() view returns(bytes32)
   225  func (_UniswapV2ERC20 *UniswapV2ERC20Session) DOMAINSEPARATOR() ([32]byte, error) {
   226  	return _UniswapV2ERC20.Contract.DOMAINSEPARATOR(&_UniswapV2ERC20.CallOpts)
   227  }
   228  
   229  // DOMAINSEPARATOR is a free data retrieval call binding the contract method 0x3644e515.
   230  //
   231  // Solidity: function DOMAIN_SEPARATOR() view returns(bytes32)
   232  func (_UniswapV2ERC20 *UniswapV2ERC20CallerSession) DOMAINSEPARATOR() ([32]byte, error) {
   233  	return _UniswapV2ERC20.Contract.DOMAINSEPARATOR(&_UniswapV2ERC20.CallOpts)
   234  }
   235  
   236  // PERMITTYPEHASH is a free data retrieval call binding the contract method 0x30adf81f.
   237  //
   238  // Solidity: function PERMIT_TYPEHASH() view returns(bytes32)
   239  func (_UniswapV2ERC20 *UniswapV2ERC20Caller) PERMITTYPEHASH(opts *bind.CallOpts) ([32]byte, error) {
   240  	var out []interface{}
   241  	err := _UniswapV2ERC20.contract.Call(opts, &out, "PERMIT_TYPEHASH")
   242  
   243  	if err != nil {
   244  		return *new([32]byte), err
   245  	}
   246  
   247  	out0 := *abi.ConvertType(out[0], new([32]byte)).(*[32]byte)
   248  
   249  	return out0, err
   250  
   251  }
   252  
   253  // PERMITTYPEHASH is a free data retrieval call binding the contract method 0x30adf81f.
   254  //
   255  // Solidity: function PERMIT_TYPEHASH() view returns(bytes32)
   256  func (_UniswapV2ERC20 *UniswapV2ERC20Session) PERMITTYPEHASH() ([32]byte, error) {
   257  	return _UniswapV2ERC20.Contract.PERMITTYPEHASH(&_UniswapV2ERC20.CallOpts)
   258  }
   259  
   260  // PERMITTYPEHASH is a free data retrieval call binding the contract method 0x30adf81f.
   261  //
   262  // Solidity: function PERMIT_TYPEHASH() view returns(bytes32)
   263  func (_UniswapV2ERC20 *UniswapV2ERC20CallerSession) PERMITTYPEHASH() ([32]byte, error) {
   264  	return _UniswapV2ERC20.Contract.PERMITTYPEHASH(&_UniswapV2ERC20.CallOpts)
   265  }
   266  
   267  // Allowance is a free data retrieval call binding the contract method 0xdd62ed3e.
   268  //
   269  // Solidity: function allowance(address , address ) view returns(uint256)
   270  func (_UniswapV2ERC20 *UniswapV2ERC20Caller) Allowance(opts *bind.CallOpts, arg0 common.Address, arg1 common.Address) (*big.Int, error) {
   271  	var out []interface{}
   272  	err := _UniswapV2ERC20.contract.Call(opts, &out, "allowance", arg0, arg1)
   273  
   274  	if err != nil {
   275  		return *new(*big.Int), err
   276  	}
   277  
   278  	out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int)
   279  
   280  	return out0, err
   281  
   282  }
   283  
   284  // Allowance is a free data retrieval call binding the contract method 0xdd62ed3e.
   285  //
   286  // Solidity: function allowance(address , address ) view returns(uint256)
   287  func (_UniswapV2ERC20 *UniswapV2ERC20Session) Allowance(arg0 common.Address, arg1 common.Address) (*big.Int, error) {
   288  	return _UniswapV2ERC20.Contract.Allowance(&_UniswapV2ERC20.CallOpts, arg0, arg1)
   289  }
   290  
   291  // Allowance is a free data retrieval call binding the contract method 0xdd62ed3e.
   292  //
   293  // Solidity: function allowance(address , address ) view returns(uint256)
   294  func (_UniswapV2ERC20 *UniswapV2ERC20CallerSession) Allowance(arg0 common.Address, arg1 common.Address) (*big.Int, error) {
   295  	return _UniswapV2ERC20.Contract.Allowance(&_UniswapV2ERC20.CallOpts, arg0, arg1)
   296  }
   297  
   298  // BalanceOf is a free data retrieval call binding the contract method 0x70a08231.
   299  //
   300  // Solidity: function balanceOf(address ) view returns(uint256)
   301  func (_UniswapV2ERC20 *UniswapV2ERC20Caller) BalanceOf(opts *bind.CallOpts, arg0 common.Address) (*big.Int, error) {
   302  	var out []interface{}
   303  	err := _UniswapV2ERC20.contract.Call(opts, &out, "balanceOf", arg0)
   304  
   305  	if err != nil {
   306  		return *new(*big.Int), err
   307  	}
   308  
   309  	out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int)
   310  
   311  	return out0, err
   312  
   313  }
   314  
   315  // BalanceOf is a free data retrieval call binding the contract method 0x70a08231.
   316  //
   317  // Solidity: function balanceOf(address ) view returns(uint256)
   318  func (_UniswapV2ERC20 *UniswapV2ERC20Session) BalanceOf(arg0 common.Address) (*big.Int, error) {
   319  	return _UniswapV2ERC20.Contract.BalanceOf(&_UniswapV2ERC20.CallOpts, arg0)
   320  }
   321  
   322  // BalanceOf is a free data retrieval call binding the contract method 0x70a08231.
   323  //
   324  // Solidity: function balanceOf(address ) view returns(uint256)
   325  func (_UniswapV2ERC20 *UniswapV2ERC20CallerSession) BalanceOf(arg0 common.Address) (*big.Int, error) {
   326  	return _UniswapV2ERC20.Contract.BalanceOf(&_UniswapV2ERC20.CallOpts, arg0)
   327  }
   328  
   329  // Decimals is a free data retrieval call binding the contract method 0x313ce567.
   330  //
   331  // Solidity: function decimals() view returns(uint8)
   332  func (_UniswapV2ERC20 *UniswapV2ERC20Caller) Decimals(opts *bind.CallOpts) (uint8, error) {
   333  	var out []interface{}
   334  	err := _UniswapV2ERC20.contract.Call(opts, &out, "decimals")
   335  
   336  	if err != nil {
   337  		return *new(uint8), err
   338  	}
   339  
   340  	out0 := *abi.ConvertType(out[0], new(uint8)).(*uint8)
   341  
   342  	return out0, err
   343  
   344  }
   345  
   346  // Decimals is a free data retrieval call binding the contract method 0x313ce567.
   347  //
   348  // Solidity: function decimals() view returns(uint8)
   349  func (_UniswapV2ERC20 *UniswapV2ERC20Session) Decimals() (uint8, error) {
   350  	return _UniswapV2ERC20.Contract.Decimals(&_UniswapV2ERC20.CallOpts)
   351  }
   352  
   353  // Decimals is a free data retrieval call binding the contract method 0x313ce567.
   354  //
   355  // Solidity: function decimals() view returns(uint8)
   356  func (_UniswapV2ERC20 *UniswapV2ERC20CallerSession) Decimals() (uint8, error) {
   357  	return _UniswapV2ERC20.Contract.Decimals(&_UniswapV2ERC20.CallOpts)
   358  }
   359  
   360  // Name is a free data retrieval call binding the contract method 0x06fdde03.
   361  //
   362  // Solidity: function name() view returns(string)
   363  func (_UniswapV2ERC20 *UniswapV2ERC20Caller) Name(opts *bind.CallOpts) (string, error) {
   364  	var out []interface{}
   365  	err := _UniswapV2ERC20.contract.Call(opts, &out, "name")
   366  
   367  	if err != nil {
   368  		return *new(string), err
   369  	}
   370  
   371  	out0 := *abi.ConvertType(out[0], new(string)).(*string)
   372  
   373  	return out0, err
   374  
   375  }
   376  
   377  // Name is a free data retrieval call binding the contract method 0x06fdde03.
   378  //
   379  // Solidity: function name() view returns(string)
   380  func (_UniswapV2ERC20 *UniswapV2ERC20Session) Name() (string, error) {
   381  	return _UniswapV2ERC20.Contract.Name(&_UniswapV2ERC20.CallOpts)
   382  }
   383  
   384  // Name is a free data retrieval call binding the contract method 0x06fdde03.
   385  //
   386  // Solidity: function name() view returns(string)
   387  func (_UniswapV2ERC20 *UniswapV2ERC20CallerSession) Name() (string, error) {
   388  	return _UniswapV2ERC20.Contract.Name(&_UniswapV2ERC20.CallOpts)
   389  }
   390  
   391  // Nonces is a free data retrieval call binding the contract method 0x7ecebe00.
   392  //
   393  // Solidity: function nonces(address ) view returns(uint256)
   394  func (_UniswapV2ERC20 *UniswapV2ERC20Caller) Nonces(opts *bind.CallOpts, arg0 common.Address) (*big.Int, error) {
   395  	var out []interface{}
   396  	err := _UniswapV2ERC20.contract.Call(opts, &out, "nonces", arg0)
   397  
   398  	if err != nil {
   399  		return *new(*big.Int), err
   400  	}
   401  
   402  	out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int)
   403  
   404  	return out0, err
   405  
   406  }
   407  
   408  // Nonces is a free data retrieval call binding the contract method 0x7ecebe00.
   409  //
   410  // Solidity: function nonces(address ) view returns(uint256)
   411  func (_UniswapV2ERC20 *UniswapV2ERC20Session) Nonces(arg0 common.Address) (*big.Int, error) {
   412  	return _UniswapV2ERC20.Contract.Nonces(&_UniswapV2ERC20.CallOpts, arg0)
   413  }
   414  
   415  // Nonces is a free data retrieval call binding the contract method 0x7ecebe00.
   416  //
   417  // Solidity: function nonces(address ) view returns(uint256)
   418  func (_UniswapV2ERC20 *UniswapV2ERC20CallerSession) Nonces(arg0 common.Address) (*big.Int, error) {
   419  	return _UniswapV2ERC20.Contract.Nonces(&_UniswapV2ERC20.CallOpts, arg0)
   420  }
   421  
   422  // Symbol is a free data retrieval call binding the contract method 0x95d89b41.
   423  //
   424  // Solidity: function symbol() view returns(string)
   425  func (_UniswapV2ERC20 *UniswapV2ERC20Caller) Symbol(opts *bind.CallOpts) (string, error) {
   426  	var out []interface{}
   427  	err := _UniswapV2ERC20.contract.Call(opts, &out, "symbol")
   428  
   429  	if err != nil {
   430  		return *new(string), err
   431  	}
   432  
   433  	out0 := *abi.ConvertType(out[0], new(string)).(*string)
   434  
   435  	return out0, err
   436  
   437  }
   438  
   439  // Symbol is a free data retrieval call binding the contract method 0x95d89b41.
   440  //
   441  // Solidity: function symbol() view returns(string)
   442  func (_UniswapV2ERC20 *UniswapV2ERC20Session) Symbol() (string, error) {
   443  	return _UniswapV2ERC20.Contract.Symbol(&_UniswapV2ERC20.CallOpts)
   444  }
   445  
   446  // Symbol is a free data retrieval call binding the contract method 0x95d89b41.
   447  //
   448  // Solidity: function symbol() view returns(string)
   449  func (_UniswapV2ERC20 *UniswapV2ERC20CallerSession) Symbol() (string, error) {
   450  	return _UniswapV2ERC20.Contract.Symbol(&_UniswapV2ERC20.CallOpts)
   451  }
   452  
   453  // TotalSupply is a free data retrieval call binding the contract method 0x18160ddd.
   454  //
   455  // Solidity: function totalSupply() view returns(uint256)
   456  func (_UniswapV2ERC20 *UniswapV2ERC20Caller) TotalSupply(opts *bind.CallOpts) (*big.Int, error) {
   457  	var out []interface{}
   458  	err := _UniswapV2ERC20.contract.Call(opts, &out, "totalSupply")
   459  
   460  	if err != nil {
   461  		return *new(*big.Int), err
   462  	}
   463  
   464  	out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int)
   465  
   466  	return out0, err
   467  
   468  }
   469  
   470  // TotalSupply is a free data retrieval call binding the contract method 0x18160ddd.
   471  //
   472  // Solidity: function totalSupply() view returns(uint256)
   473  func (_UniswapV2ERC20 *UniswapV2ERC20Session) TotalSupply() (*big.Int, error) {
   474  	return _UniswapV2ERC20.Contract.TotalSupply(&_UniswapV2ERC20.CallOpts)
   475  }
   476  
   477  // TotalSupply is a free data retrieval call binding the contract method 0x18160ddd.
   478  //
   479  // Solidity: function totalSupply() view returns(uint256)
   480  func (_UniswapV2ERC20 *UniswapV2ERC20CallerSession) TotalSupply() (*big.Int, error) {
   481  	return _UniswapV2ERC20.Contract.TotalSupply(&_UniswapV2ERC20.CallOpts)
   482  }
   483  
   484  // Approve is a paid mutator transaction binding the contract method 0x095ea7b3.
   485  //
   486  // Solidity: function approve(address spender, uint256 value) returns(bool)
   487  func (_UniswapV2ERC20 *UniswapV2ERC20Transactor) Approve(opts *bind.TransactOpts, spender common.Address, value *big.Int) (*types.Transaction, error) {
   488  	return _UniswapV2ERC20.contract.Transact(opts, "approve", spender, value)
   489  }
   490  
   491  // Approve is a paid mutator transaction binding the contract method 0x095ea7b3.
   492  //
   493  // Solidity: function approve(address spender, uint256 value) returns(bool)
   494  func (_UniswapV2ERC20 *UniswapV2ERC20Session) Approve(spender common.Address, value *big.Int) (*types.Transaction, error) {
   495  	return _UniswapV2ERC20.Contract.Approve(&_UniswapV2ERC20.TransactOpts, spender, value)
   496  }
   497  
   498  // Approve is a paid mutator transaction binding the contract method 0x095ea7b3.
   499  //
   500  // Solidity: function approve(address spender, uint256 value) returns(bool)
   501  func (_UniswapV2ERC20 *UniswapV2ERC20TransactorSession) Approve(spender common.Address, value *big.Int) (*types.Transaction, error) {
   502  	return _UniswapV2ERC20.Contract.Approve(&_UniswapV2ERC20.TransactOpts, spender, value)
   503  }
   504  
   505  // Permit is a paid mutator transaction binding the contract method 0xd505accf.
   506  //
   507  // Solidity: function permit(address owner, address spender, uint256 value, uint256 deadline, uint8 v, bytes32 r, bytes32 s) returns()
   508  func (_UniswapV2ERC20 *UniswapV2ERC20Transactor) Permit(opts *bind.TransactOpts, owner common.Address, spender common.Address, value *big.Int, deadline *big.Int, v uint8, r [32]byte, s [32]byte) (*types.Transaction, error) {
   509  	return _UniswapV2ERC20.contract.Transact(opts, "permit", owner, spender, value, deadline, v, r, s)
   510  }
   511  
   512  // Permit is a paid mutator transaction binding the contract method 0xd505accf.
   513  //
   514  // Solidity: function permit(address owner, address spender, uint256 value, uint256 deadline, uint8 v, bytes32 r, bytes32 s) returns()
   515  func (_UniswapV2ERC20 *UniswapV2ERC20Session) Permit(owner common.Address, spender common.Address, value *big.Int, deadline *big.Int, v uint8, r [32]byte, s [32]byte) (*types.Transaction, error) {
   516  	return _UniswapV2ERC20.Contract.Permit(&_UniswapV2ERC20.TransactOpts, owner, spender, value, deadline, v, r, s)
   517  }
   518  
   519  // Permit is a paid mutator transaction binding the contract method 0xd505accf.
   520  //
   521  // Solidity: function permit(address owner, address spender, uint256 value, uint256 deadline, uint8 v, bytes32 r, bytes32 s) returns()
   522  func (_UniswapV2ERC20 *UniswapV2ERC20TransactorSession) Permit(owner common.Address, spender common.Address, value *big.Int, deadline *big.Int, v uint8, r [32]byte, s [32]byte) (*types.Transaction, error) {
   523  	return _UniswapV2ERC20.Contract.Permit(&_UniswapV2ERC20.TransactOpts, owner, spender, value, deadline, v, r, s)
   524  }
   525  
   526  // Transfer is a paid mutator transaction binding the contract method 0xa9059cbb.
   527  //
   528  // Solidity: function transfer(address to, uint256 value) returns(bool)
   529  func (_UniswapV2ERC20 *UniswapV2ERC20Transactor) Transfer(opts *bind.TransactOpts, to common.Address, value *big.Int) (*types.Transaction, error) {
   530  	return _UniswapV2ERC20.contract.Transact(opts, "transfer", to, value)
   531  }
   532  
   533  // Transfer is a paid mutator transaction binding the contract method 0xa9059cbb.
   534  //
   535  // Solidity: function transfer(address to, uint256 value) returns(bool)
   536  func (_UniswapV2ERC20 *UniswapV2ERC20Session) Transfer(to common.Address, value *big.Int) (*types.Transaction, error) {
   537  	return _UniswapV2ERC20.Contract.Transfer(&_UniswapV2ERC20.TransactOpts, to, value)
   538  }
   539  
   540  // Transfer is a paid mutator transaction binding the contract method 0xa9059cbb.
   541  //
   542  // Solidity: function transfer(address to, uint256 value) returns(bool)
   543  func (_UniswapV2ERC20 *UniswapV2ERC20TransactorSession) Transfer(to common.Address, value *big.Int) (*types.Transaction, error) {
   544  	return _UniswapV2ERC20.Contract.Transfer(&_UniswapV2ERC20.TransactOpts, to, value)
   545  }
   546  
   547  // TransferFrom is a paid mutator transaction binding the contract method 0x23b872dd.
   548  //
   549  // Solidity: function transferFrom(address from, address to, uint256 value) returns(bool)
   550  func (_UniswapV2ERC20 *UniswapV2ERC20Transactor) TransferFrom(opts *bind.TransactOpts, from common.Address, to common.Address, value *big.Int) (*types.Transaction, error) {
   551  	return _UniswapV2ERC20.contract.Transact(opts, "transferFrom", from, to, value)
   552  }
   553  
   554  // TransferFrom is a paid mutator transaction binding the contract method 0x23b872dd.
   555  //
   556  // Solidity: function transferFrom(address from, address to, uint256 value) returns(bool)
   557  func (_UniswapV2ERC20 *UniswapV2ERC20Session) TransferFrom(from common.Address, to common.Address, value *big.Int) (*types.Transaction, error) {
   558  	return _UniswapV2ERC20.Contract.TransferFrom(&_UniswapV2ERC20.TransactOpts, from, to, value)
   559  }
   560  
   561  // TransferFrom is a paid mutator transaction binding the contract method 0x23b872dd.
   562  //
   563  // Solidity: function transferFrom(address from, address to, uint256 value) returns(bool)
   564  func (_UniswapV2ERC20 *UniswapV2ERC20TransactorSession) TransferFrom(from common.Address, to common.Address, value *big.Int) (*types.Transaction, error) {
   565  	return _UniswapV2ERC20.Contract.TransferFrom(&_UniswapV2ERC20.TransactOpts, from, to, value)
   566  }
   567  
   568  // UniswapV2ERC20ApprovalIterator is returned from FilterApproval and is used to iterate over the raw logs and unpacked data for Approval events raised by the UniswapV2ERC20 contract.
   569  type UniswapV2ERC20ApprovalIterator struct {
   570  	Event *UniswapV2ERC20Approval // Event containing the contract specifics and raw log
   571  
   572  	contract *bind.BoundContract // Generic contract to use for unpacking event data
   573  	event    string              // Event name to use for unpacking event data
   574  
   575  	logs chan types.Log        // Log channel receiving the found contract events
   576  	sub  ethereum.Subscription // Subscription for errors, completion and termination
   577  	done bool                  // Whether the subscription completed delivering logs
   578  	fail error                 // Occurred error to stop iteration
   579  }
   580  
   581  // Next advances the iterator to the subsequent event, returning whether there
   582  // are any more events found. In case of a retrieval or parsing error, false is
   583  // returned and Error() can be queried for the exact failure.
   584  func (it *UniswapV2ERC20ApprovalIterator) Next() bool {
   585  	// If the iterator failed, stop iterating
   586  	if it.fail != nil {
   587  		return false
   588  	}
   589  	// If the iterator completed, deliver directly whatever's available
   590  	if it.done {
   591  		select {
   592  		case log := <-it.logs:
   593  			it.Event = new(UniswapV2ERC20Approval)
   594  			if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil {
   595  				it.fail = err
   596  				return false
   597  			}
   598  			it.Event.Raw = log
   599  			return true
   600  
   601  		default:
   602  			return false
   603  		}
   604  	}
   605  	// Iterator still in progress, wait for either a data or an error event
   606  	select {
   607  	case log := <-it.logs:
   608  		it.Event = new(UniswapV2ERC20Approval)
   609  		if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil {
   610  			it.fail = err
   611  			return false
   612  		}
   613  		it.Event.Raw = log
   614  		return true
   615  
   616  	case err := <-it.sub.Err():
   617  		it.done = true
   618  		it.fail = err
   619  		return it.Next()
   620  	}
   621  }
   622  
   623  // Error returns any retrieval or parsing error occurred during filtering.
   624  func (it *UniswapV2ERC20ApprovalIterator) Error() error {
   625  	return it.fail
   626  }
   627  
   628  // Close terminates the iteration process, releasing any pending underlying
   629  // resources.
   630  func (it *UniswapV2ERC20ApprovalIterator) Close() error {
   631  	it.sub.Unsubscribe()
   632  	return nil
   633  }
   634  
   635  // UniswapV2ERC20Approval represents a Approval event raised by the UniswapV2ERC20 contract.
   636  type UniswapV2ERC20Approval struct {
   637  	Owner   common.Address
   638  	Spender common.Address
   639  	Value   *big.Int
   640  	Raw     types.Log // Blockchain specific contextual infos
   641  }
   642  
   643  // FilterApproval is a free log retrieval operation binding the contract event 0x8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925.
   644  //
   645  // Solidity: event Approval(address indexed owner, address indexed spender, uint256 value)
   646  func (_UniswapV2ERC20 *UniswapV2ERC20Filterer) FilterApproval(opts *bind.FilterOpts, owner []common.Address, spender []common.Address) (*UniswapV2ERC20ApprovalIterator, error) {
   647  
   648  	var ownerRule []interface{}
   649  	for _, ownerItem := range owner {
   650  		ownerRule = append(ownerRule, ownerItem)
   651  	}
   652  	var spenderRule []interface{}
   653  	for _, spenderItem := range spender {
   654  		spenderRule = append(spenderRule, spenderItem)
   655  	}
   656  
   657  	logs, sub, err := _UniswapV2ERC20.contract.FilterLogs(opts, "Approval", ownerRule, spenderRule)
   658  	if err != nil {
   659  		return nil, err
   660  	}
   661  	return &UniswapV2ERC20ApprovalIterator{contract: _UniswapV2ERC20.contract, event: "Approval", logs: logs, sub: sub}, nil
   662  }
   663  
   664  // WatchApproval is a free log subscription operation binding the contract event 0x8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925.
   665  //
   666  // Solidity: event Approval(address indexed owner, address indexed spender, uint256 value)
   667  func (_UniswapV2ERC20 *UniswapV2ERC20Filterer) WatchApproval(opts *bind.WatchOpts, sink chan<- *UniswapV2ERC20Approval, owner []common.Address, spender []common.Address) (event.Subscription, error) {
   668  
   669  	var ownerRule []interface{}
   670  	for _, ownerItem := range owner {
   671  		ownerRule = append(ownerRule, ownerItem)
   672  	}
   673  	var spenderRule []interface{}
   674  	for _, spenderItem := range spender {
   675  		spenderRule = append(spenderRule, spenderItem)
   676  	}
   677  
   678  	logs, sub, err := _UniswapV2ERC20.contract.WatchLogs(opts, "Approval", ownerRule, spenderRule)
   679  	if err != nil {
   680  		return nil, err
   681  	}
   682  	return event.NewSubscription(func(quit <-chan struct{}) error {
   683  		defer sub.Unsubscribe()
   684  		for {
   685  			select {
   686  			case log := <-logs:
   687  				// New log arrived, parse the event and forward to the user
   688  				event := new(UniswapV2ERC20Approval)
   689  				if err := _UniswapV2ERC20.contract.UnpackLog(event, "Approval", log); err != nil {
   690  					return err
   691  				}
   692  				event.Raw = log
   693  
   694  				select {
   695  				case sink <- event:
   696  				case err := <-sub.Err():
   697  					return err
   698  				case <-quit:
   699  					return nil
   700  				}
   701  			case err := <-sub.Err():
   702  				return err
   703  			case <-quit:
   704  				return nil
   705  			}
   706  		}
   707  	}), nil
   708  }
   709  
   710  // ParseApproval is a log parse operation binding the contract event 0x8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925.
   711  //
   712  // Solidity: event Approval(address indexed owner, address indexed spender, uint256 value)
   713  func (_UniswapV2ERC20 *UniswapV2ERC20Filterer) ParseApproval(log types.Log) (*UniswapV2ERC20Approval, error) {
   714  	event := new(UniswapV2ERC20Approval)
   715  	if err := _UniswapV2ERC20.contract.UnpackLog(event, "Approval", log); err != nil {
   716  		return nil, err
   717  	}
   718  	event.Raw = log
   719  	return event, nil
   720  }
   721  
   722  // UniswapV2ERC20TransferIterator is returned from FilterTransfer and is used to iterate over the raw logs and unpacked data for Transfer events raised by the UniswapV2ERC20 contract.
   723  type UniswapV2ERC20TransferIterator struct {
   724  	Event *UniswapV2ERC20Transfer // Event containing the contract specifics and raw log
   725  
   726  	contract *bind.BoundContract // Generic contract to use for unpacking event data
   727  	event    string              // Event name to use for unpacking event data
   728  
   729  	logs chan types.Log        // Log channel receiving the found contract events
   730  	sub  ethereum.Subscription // Subscription for errors, completion and termination
   731  	done bool                  // Whether the subscription completed delivering logs
   732  	fail error                 // Occurred error to stop iteration
   733  }
   734  
   735  // Next advances the iterator to the subsequent event, returning whether there
   736  // are any more events found. In case of a retrieval or parsing error, false is
   737  // returned and Error() can be queried for the exact failure.
   738  func (it *UniswapV2ERC20TransferIterator) Next() bool {
   739  	// If the iterator failed, stop iterating
   740  	if it.fail != nil {
   741  		return false
   742  	}
   743  	// If the iterator completed, deliver directly whatever's available
   744  	if it.done {
   745  		select {
   746  		case log := <-it.logs:
   747  			it.Event = new(UniswapV2ERC20Transfer)
   748  			if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil {
   749  				it.fail = err
   750  				return false
   751  			}
   752  			it.Event.Raw = log
   753  			return true
   754  
   755  		default:
   756  			return false
   757  		}
   758  	}
   759  	// Iterator still in progress, wait for either a data or an error event
   760  	select {
   761  	case log := <-it.logs:
   762  		it.Event = new(UniswapV2ERC20Transfer)
   763  		if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil {
   764  			it.fail = err
   765  			return false
   766  		}
   767  		it.Event.Raw = log
   768  		return true
   769  
   770  	case err := <-it.sub.Err():
   771  		it.done = true
   772  		it.fail = err
   773  		return it.Next()
   774  	}
   775  }
   776  
   777  // Error returns any retrieval or parsing error occurred during filtering.
   778  func (it *UniswapV2ERC20TransferIterator) Error() error {
   779  	return it.fail
   780  }
   781  
   782  // Close terminates the iteration process, releasing any pending underlying
   783  // resources.
   784  func (it *UniswapV2ERC20TransferIterator) Close() error {
   785  	it.sub.Unsubscribe()
   786  	return nil
   787  }
   788  
   789  // UniswapV2ERC20Transfer represents a Transfer event raised by the UniswapV2ERC20 contract.
   790  type UniswapV2ERC20Transfer struct {
   791  	From  common.Address
   792  	To    common.Address
   793  	Value *big.Int
   794  	Raw   types.Log // Blockchain specific contextual infos
   795  }
   796  
   797  // FilterTransfer is a free log retrieval operation binding the contract event 0xddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef.
   798  //
   799  // Solidity: event Transfer(address indexed from, address indexed to, uint256 value)
   800  func (_UniswapV2ERC20 *UniswapV2ERC20Filterer) FilterTransfer(opts *bind.FilterOpts, from []common.Address, to []common.Address) (*UniswapV2ERC20TransferIterator, error) {
   801  
   802  	var fromRule []interface{}
   803  	for _, fromItem := range from {
   804  		fromRule = append(fromRule, fromItem)
   805  	}
   806  	var toRule []interface{}
   807  	for _, toItem := range to {
   808  		toRule = append(toRule, toItem)
   809  	}
   810  
   811  	logs, sub, err := _UniswapV2ERC20.contract.FilterLogs(opts, "Transfer", fromRule, toRule)
   812  	if err != nil {
   813  		return nil, err
   814  	}
   815  	return &UniswapV2ERC20TransferIterator{contract: _UniswapV2ERC20.contract, event: "Transfer", logs: logs, sub: sub}, nil
   816  }
   817  
   818  // WatchTransfer is a free log subscription operation binding the contract event 0xddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef.
   819  //
   820  // Solidity: event Transfer(address indexed from, address indexed to, uint256 value)
   821  func (_UniswapV2ERC20 *UniswapV2ERC20Filterer) WatchTransfer(opts *bind.WatchOpts, sink chan<- *UniswapV2ERC20Transfer, from []common.Address, to []common.Address) (event.Subscription, error) {
   822  
   823  	var fromRule []interface{}
   824  	for _, fromItem := range from {
   825  		fromRule = append(fromRule, fromItem)
   826  	}
   827  	var toRule []interface{}
   828  	for _, toItem := range to {
   829  		toRule = append(toRule, toItem)
   830  	}
   831  
   832  	logs, sub, err := _UniswapV2ERC20.contract.WatchLogs(opts, "Transfer", fromRule, toRule)
   833  	if err != nil {
   834  		return nil, err
   835  	}
   836  	return event.NewSubscription(func(quit <-chan struct{}) error {
   837  		defer sub.Unsubscribe()
   838  		for {
   839  			select {
   840  			case log := <-logs:
   841  				// New log arrived, parse the event and forward to the user
   842  				event := new(UniswapV2ERC20Transfer)
   843  				if err := _UniswapV2ERC20.contract.UnpackLog(event, "Transfer", log); err != nil {
   844  					return err
   845  				}
   846  				event.Raw = log
   847  
   848  				select {
   849  				case sink <- event:
   850  				case err := <-sub.Err():
   851  					return err
   852  				case <-quit:
   853  					return nil
   854  				}
   855  			case err := <-sub.Err():
   856  				return err
   857  			case <-quit:
   858  				return nil
   859  			}
   860  		}
   861  	}), nil
   862  }
   863  
   864  // ParseTransfer is a log parse operation binding the contract event 0xddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef.
   865  //
   866  // Solidity: event Transfer(address indexed from, address indexed to, uint256 value)
   867  func (_UniswapV2ERC20 *UniswapV2ERC20Filterer) ParseTransfer(log types.Log) (*UniswapV2ERC20Transfer, error) {
   868  	event := new(UniswapV2ERC20Transfer)
   869  	if err := _UniswapV2ERC20.contract.UnpackLog(event, "Transfer", log); err != nil {
   870  		return nil, err
   871  	}
   872  	event.Raw = log
   873  	return event, nil
   874  }