github.com/cwntr/go-defi@v0.0.0-20210629134751-07f9ec2f7e66/binding/yearn/yweth/yweth.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 yweth 5 6 import ( 7 "math/big" 8 "strings" 9 10 ethereum "github.com/ethereum/go-ethereum" 11 "github.com/ethereum/go-ethereum/accounts/abi" 12 "github.com/ethereum/go-ethereum/accounts/abi/bind" 13 "github.com/ethereum/go-ethereum/common" 14 "github.com/ethereum/go-ethereum/core/types" 15 "github.com/ethereum/go-ethereum/event" 16 ) 17 18 // Reference imports to suppress errors if they are not otherwise used. 19 var ( 20 _ = big.NewInt 21 _ = strings.NewReader 22 _ = ethereum.NotFound 23 _ = bind.Bind 24 _ = common.Big1 25 _ = types.BloomLookup 26 _ = event.NewSubscription 27 ) 28 29 // YwethABI is the input ABI used to generate the binding from. 30 const YwethABI = "[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"_token\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"_controller\",\"type\":\"address\"}],\"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\"},{\"payable\":true,\"stateMutability\":\"payable\",\"type\":\"fallback\"},{\"constant\":true,\"inputs\":[{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"spender\",\"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\":\"amount\",\"type\":\"uint256\"}],\"name\":\"approve\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"available\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"balance\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"balanceOf\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"controller\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"decimals\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"\",\"type\":\"uint8\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"internalType\":\"address\",\"name\":\"spender\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"subtractedValue\",\"type\":\"uint256\"}],\"name\":\"decreaseAllowance\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"_amount\",\"type\":\"uint256\"}],\"name\":\"deposit\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[],\"name\":\"depositAll\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[],\"name\":\"depositETH\",\"outputs\":[],\"payable\":true,\"stateMutability\":\"payable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[],\"name\":\"earn\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"getPricePerFullShare\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"governance\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"internalType\":\"address\",\"name\":\"reserve\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"harvest\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"internalType\":\"address\",\"name\":\"spender\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"addedValue\",\"type\":\"uint256\"}],\"name\":\"increaseAllowance\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"max\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"min\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"name\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"internalType\":\"address\",\"name\":\"_controller\",\"type\":\"address\"}],\"name\":\"setController\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"internalType\":\"address\",\"name\":\"_governance\",\"type\":\"address\"}],\"name\":\"setGovernance\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"_min\",\"type\":\"uint256\"}],\"name\":\"setMin\",\"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\":\"token\",\"outputs\":[{\"internalType\":\"contractIERC20\",\"name\":\"\",\"type\":\"address\"}],\"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\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"transfer\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"transferFrom\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"_shares\",\"type\":\"uint256\"}],\"name\":\"withdraw\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[],\"name\":\"withdrawAll\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[],\"name\":\"withdrawAllETH\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"_shares\",\"type\":\"uint256\"}],\"name\":\"withdrawETH\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]" 31 32 // Yweth is an auto generated Go binding around an Ethereum contract. 33 type Yweth struct { 34 YwethCaller // Read-only binding to the contract 35 YwethTransactor // Write-only binding to the contract 36 YwethFilterer // Log filterer for contract events 37 } 38 39 // YwethCaller is an auto generated read-only Go binding around an Ethereum contract. 40 type YwethCaller struct { 41 contract *bind.BoundContract // Generic contract wrapper for the low level calls 42 } 43 44 // YwethTransactor is an auto generated write-only Go binding around an Ethereum contract. 45 type YwethTransactor struct { 46 contract *bind.BoundContract // Generic contract wrapper for the low level calls 47 } 48 49 // YwethFilterer is an auto generated log filtering Go binding around an Ethereum contract events. 50 type YwethFilterer struct { 51 contract *bind.BoundContract // Generic contract wrapper for the low level calls 52 } 53 54 // YwethSession is an auto generated Go binding around an Ethereum contract, 55 // with pre-set call and transact options. 56 type YwethSession struct { 57 Contract *Yweth // Generic contract binding to set the session for 58 CallOpts bind.CallOpts // Call options to use throughout this session 59 TransactOpts bind.TransactOpts // Transaction auth options to use throughout this session 60 } 61 62 // YwethCallerSession is an auto generated read-only Go binding around an Ethereum contract, 63 // with pre-set call options. 64 type YwethCallerSession struct { 65 Contract *YwethCaller // Generic contract caller binding to set the session for 66 CallOpts bind.CallOpts // Call options to use throughout this session 67 } 68 69 // YwethTransactorSession is an auto generated write-only Go binding around an Ethereum contract, 70 // with pre-set transact options. 71 type YwethTransactorSession struct { 72 Contract *YwethTransactor // Generic contract transactor binding to set the session for 73 TransactOpts bind.TransactOpts // Transaction auth options to use throughout this session 74 } 75 76 // YwethRaw is an auto generated low-level Go binding around an Ethereum contract. 77 type YwethRaw struct { 78 Contract *Yweth // Generic contract binding to access the raw methods on 79 } 80 81 // YwethCallerRaw is an auto generated low-level read-only Go binding around an Ethereum contract. 82 type YwethCallerRaw struct { 83 Contract *YwethCaller // Generic read-only contract binding to access the raw methods on 84 } 85 86 // YwethTransactorRaw is an auto generated low-level write-only Go binding around an Ethereum contract. 87 type YwethTransactorRaw struct { 88 Contract *YwethTransactor // Generic write-only contract binding to access the raw methods on 89 } 90 91 // NewYweth creates a new instance of Yweth, bound to a specific deployed contract. 92 func NewYweth(address common.Address, backend bind.ContractBackend) (*Yweth, error) { 93 contract, err := bindYweth(address, backend, backend, backend) 94 if err != nil { 95 return nil, err 96 } 97 return &Yweth{YwethCaller: YwethCaller{contract: contract}, YwethTransactor: YwethTransactor{contract: contract}, YwethFilterer: YwethFilterer{contract: contract}}, nil 98 } 99 100 // NewYwethCaller creates a new read-only instance of Yweth, bound to a specific deployed contract. 101 func NewYwethCaller(address common.Address, caller bind.ContractCaller) (*YwethCaller, error) { 102 contract, err := bindYweth(address, caller, nil, nil) 103 if err != nil { 104 return nil, err 105 } 106 return &YwethCaller{contract: contract}, nil 107 } 108 109 // NewYwethTransactor creates a new write-only instance of Yweth, bound to a specific deployed contract. 110 func NewYwethTransactor(address common.Address, transactor bind.ContractTransactor) (*YwethTransactor, error) { 111 contract, err := bindYweth(address, nil, transactor, nil) 112 if err != nil { 113 return nil, err 114 } 115 return &YwethTransactor{contract: contract}, nil 116 } 117 118 // NewYwethFilterer creates a new log filterer instance of Yweth, bound to a specific deployed contract. 119 func NewYwethFilterer(address common.Address, filterer bind.ContractFilterer) (*YwethFilterer, error) { 120 contract, err := bindYweth(address, nil, nil, filterer) 121 if err != nil { 122 return nil, err 123 } 124 return &YwethFilterer{contract: contract}, nil 125 } 126 127 // bindYweth binds a generic wrapper to an already deployed contract. 128 func bindYweth(address common.Address, caller bind.ContractCaller, transactor bind.ContractTransactor, filterer bind.ContractFilterer) (*bind.BoundContract, error) { 129 parsed, err := abi.JSON(strings.NewReader(YwethABI)) 130 if err != nil { 131 return nil, err 132 } 133 return bind.NewBoundContract(address, parsed, caller, transactor, filterer), nil 134 } 135 136 // Call invokes the (constant) contract method with params as input values and 137 // sets the output to result. The result type might be a single field for simple 138 // returns, a slice of interfaces for anonymous returns and a struct for named 139 // returns. 140 func (_Yweth *YwethRaw) Call(opts *bind.CallOpts, result *[]interface{}, method string, params ...interface{}) error { 141 return _Yweth.Contract.YwethCaller.contract.Call(opts, result, method, params...) 142 } 143 144 // Transfer initiates a plain transaction to move funds to the contract, calling 145 // its default method if one is available. 146 func (_Yweth *YwethRaw) Transfer(opts *bind.TransactOpts) (*types.Transaction, error) { 147 return _Yweth.Contract.YwethTransactor.contract.Transfer(opts) 148 } 149 150 // Transact invokes the (paid) contract method with params as input values. 151 func (_Yweth *YwethRaw) Transact(opts *bind.TransactOpts, method string, params ...interface{}) (*types.Transaction, error) { 152 return _Yweth.Contract.YwethTransactor.contract.Transact(opts, method, params...) 153 } 154 155 // Call invokes the (constant) contract method with params as input values and 156 // sets the output to result. The result type might be a single field for simple 157 // returns, a slice of interfaces for anonymous returns and a struct for named 158 // returns. 159 func (_Yweth *YwethCallerRaw) Call(opts *bind.CallOpts, result *[]interface{}, method string, params ...interface{}) error { 160 return _Yweth.Contract.contract.Call(opts, result, method, params...) 161 } 162 163 // Transfer initiates a plain transaction to move funds to the contract, calling 164 // its default method if one is available. 165 func (_Yweth *YwethTransactorRaw) Transfer(opts *bind.TransactOpts) (*types.Transaction, error) { 166 return _Yweth.Contract.contract.Transfer(opts) 167 } 168 169 // Transact invokes the (paid) contract method with params as input values. 170 func (_Yweth *YwethTransactorRaw) Transact(opts *bind.TransactOpts, method string, params ...interface{}) (*types.Transaction, error) { 171 return _Yweth.Contract.contract.Transact(opts, method, params...) 172 } 173 174 // Allowance is a free data retrieval call binding the contract method 0xdd62ed3e. 175 // 176 // Solidity: function allowance(address owner, address spender) view returns(uint256) 177 func (_Yweth *YwethCaller) Allowance(opts *bind.CallOpts, owner common.Address, spender common.Address) (*big.Int, error) { 178 var out []interface{} 179 err := _Yweth.contract.Call(opts, &out, "allowance", owner, spender) 180 181 if err != nil { 182 return *new(*big.Int), err 183 } 184 185 out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int) 186 187 return out0, err 188 189 } 190 191 // Allowance is a free data retrieval call binding the contract method 0xdd62ed3e. 192 // 193 // Solidity: function allowance(address owner, address spender) view returns(uint256) 194 func (_Yweth *YwethSession) Allowance(owner common.Address, spender common.Address) (*big.Int, error) { 195 return _Yweth.Contract.Allowance(&_Yweth.CallOpts, owner, spender) 196 } 197 198 // Allowance is a free data retrieval call binding the contract method 0xdd62ed3e. 199 // 200 // Solidity: function allowance(address owner, address spender) view returns(uint256) 201 func (_Yweth *YwethCallerSession) Allowance(owner common.Address, spender common.Address) (*big.Int, error) { 202 return _Yweth.Contract.Allowance(&_Yweth.CallOpts, owner, spender) 203 } 204 205 // Available is a free data retrieval call binding the contract method 0x48a0d754. 206 // 207 // Solidity: function available() view returns(uint256) 208 func (_Yweth *YwethCaller) Available(opts *bind.CallOpts) (*big.Int, error) { 209 var out []interface{} 210 err := _Yweth.contract.Call(opts, &out, "available") 211 212 if err != nil { 213 return *new(*big.Int), err 214 } 215 216 out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int) 217 218 return out0, err 219 220 } 221 222 // Available is a free data retrieval call binding the contract method 0x48a0d754. 223 // 224 // Solidity: function available() view returns(uint256) 225 func (_Yweth *YwethSession) Available() (*big.Int, error) { 226 return _Yweth.Contract.Available(&_Yweth.CallOpts) 227 } 228 229 // Available is a free data retrieval call binding the contract method 0x48a0d754. 230 // 231 // Solidity: function available() view returns(uint256) 232 func (_Yweth *YwethCallerSession) Available() (*big.Int, error) { 233 return _Yweth.Contract.Available(&_Yweth.CallOpts) 234 } 235 236 // Balance is a free data retrieval call binding the contract method 0xb69ef8a8. 237 // 238 // Solidity: function balance() view returns(uint256) 239 func (_Yweth *YwethCaller) Balance(opts *bind.CallOpts) (*big.Int, error) { 240 var out []interface{} 241 err := _Yweth.contract.Call(opts, &out, "balance") 242 243 if err != nil { 244 return *new(*big.Int), err 245 } 246 247 out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int) 248 249 return out0, err 250 251 } 252 253 // Balance is a free data retrieval call binding the contract method 0xb69ef8a8. 254 // 255 // Solidity: function balance() view returns(uint256) 256 func (_Yweth *YwethSession) Balance() (*big.Int, error) { 257 return _Yweth.Contract.Balance(&_Yweth.CallOpts) 258 } 259 260 // Balance is a free data retrieval call binding the contract method 0xb69ef8a8. 261 // 262 // Solidity: function balance() view returns(uint256) 263 func (_Yweth *YwethCallerSession) Balance() (*big.Int, error) { 264 return _Yweth.Contract.Balance(&_Yweth.CallOpts) 265 } 266 267 // BalanceOf is a free data retrieval call binding the contract method 0x70a08231. 268 // 269 // Solidity: function balanceOf(address account) view returns(uint256) 270 func (_Yweth *YwethCaller) BalanceOf(opts *bind.CallOpts, account common.Address) (*big.Int, error) { 271 var out []interface{} 272 err := _Yweth.contract.Call(opts, &out, "balanceOf", account) 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 // BalanceOf is a free data retrieval call binding the contract method 0x70a08231. 285 // 286 // Solidity: function balanceOf(address account) view returns(uint256) 287 func (_Yweth *YwethSession) BalanceOf(account common.Address) (*big.Int, error) { 288 return _Yweth.Contract.BalanceOf(&_Yweth.CallOpts, account) 289 } 290 291 // BalanceOf is a free data retrieval call binding the contract method 0x70a08231. 292 // 293 // Solidity: function balanceOf(address account) view returns(uint256) 294 func (_Yweth *YwethCallerSession) BalanceOf(account common.Address) (*big.Int, error) { 295 return _Yweth.Contract.BalanceOf(&_Yweth.CallOpts, account) 296 } 297 298 // Controller is a free data retrieval call binding the contract method 0xf77c4791. 299 // 300 // Solidity: function controller() view returns(address) 301 func (_Yweth *YwethCaller) Controller(opts *bind.CallOpts) (common.Address, error) { 302 var out []interface{} 303 err := _Yweth.contract.Call(opts, &out, "controller") 304 305 if err != nil { 306 return *new(common.Address), err 307 } 308 309 out0 := *abi.ConvertType(out[0], new(common.Address)).(*common.Address) 310 311 return out0, err 312 313 } 314 315 // Controller is a free data retrieval call binding the contract method 0xf77c4791. 316 // 317 // Solidity: function controller() view returns(address) 318 func (_Yweth *YwethSession) Controller() (common.Address, error) { 319 return _Yweth.Contract.Controller(&_Yweth.CallOpts) 320 } 321 322 // Controller is a free data retrieval call binding the contract method 0xf77c4791. 323 // 324 // Solidity: function controller() view returns(address) 325 func (_Yweth *YwethCallerSession) Controller() (common.Address, error) { 326 return _Yweth.Contract.Controller(&_Yweth.CallOpts) 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 (_Yweth *YwethCaller) Decimals(opts *bind.CallOpts) (uint8, error) { 333 var out []interface{} 334 err := _Yweth.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 (_Yweth *YwethSession) Decimals() (uint8, error) { 350 return _Yweth.Contract.Decimals(&_Yweth.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 (_Yweth *YwethCallerSession) Decimals() (uint8, error) { 357 return _Yweth.Contract.Decimals(&_Yweth.CallOpts) 358 } 359 360 // GetPricePerFullShare is a free data retrieval call binding the contract method 0x77c7b8fc. 361 // 362 // Solidity: function getPricePerFullShare() view returns(uint256) 363 func (_Yweth *YwethCaller) GetPricePerFullShare(opts *bind.CallOpts) (*big.Int, error) { 364 var out []interface{} 365 err := _Yweth.contract.Call(opts, &out, "getPricePerFullShare") 366 367 if err != nil { 368 return *new(*big.Int), err 369 } 370 371 out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int) 372 373 return out0, err 374 375 } 376 377 // GetPricePerFullShare is a free data retrieval call binding the contract method 0x77c7b8fc. 378 // 379 // Solidity: function getPricePerFullShare() view returns(uint256) 380 func (_Yweth *YwethSession) GetPricePerFullShare() (*big.Int, error) { 381 return _Yweth.Contract.GetPricePerFullShare(&_Yweth.CallOpts) 382 } 383 384 // GetPricePerFullShare is a free data retrieval call binding the contract method 0x77c7b8fc. 385 // 386 // Solidity: function getPricePerFullShare() view returns(uint256) 387 func (_Yweth *YwethCallerSession) GetPricePerFullShare() (*big.Int, error) { 388 return _Yweth.Contract.GetPricePerFullShare(&_Yweth.CallOpts) 389 } 390 391 // Governance is a free data retrieval call binding the contract method 0x5aa6e675. 392 // 393 // Solidity: function governance() view returns(address) 394 func (_Yweth *YwethCaller) Governance(opts *bind.CallOpts) (common.Address, error) { 395 var out []interface{} 396 err := _Yweth.contract.Call(opts, &out, "governance") 397 398 if err != nil { 399 return *new(common.Address), err 400 } 401 402 out0 := *abi.ConvertType(out[0], new(common.Address)).(*common.Address) 403 404 return out0, err 405 406 } 407 408 // Governance is a free data retrieval call binding the contract method 0x5aa6e675. 409 // 410 // Solidity: function governance() view returns(address) 411 func (_Yweth *YwethSession) Governance() (common.Address, error) { 412 return _Yweth.Contract.Governance(&_Yweth.CallOpts) 413 } 414 415 // Governance is a free data retrieval call binding the contract method 0x5aa6e675. 416 // 417 // Solidity: function governance() view returns(address) 418 func (_Yweth *YwethCallerSession) Governance() (common.Address, error) { 419 return _Yweth.Contract.Governance(&_Yweth.CallOpts) 420 } 421 422 // Max is a free data retrieval call binding the contract method 0x6ac5db19. 423 // 424 // Solidity: function max() view returns(uint256) 425 func (_Yweth *YwethCaller) Max(opts *bind.CallOpts) (*big.Int, error) { 426 var out []interface{} 427 err := _Yweth.contract.Call(opts, &out, "max") 428 429 if err != nil { 430 return *new(*big.Int), err 431 } 432 433 out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int) 434 435 return out0, err 436 437 } 438 439 // Max is a free data retrieval call binding the contract method 0x6ac5db19. 440 // 441 // Solidity: function max() view returns(uint256) 442 func (_Yweth *YwethSession) Max() (*big.Int, error) { 443 return _Yweth.Contract.Max(&_Yweth.CallOpts) 444 } 445 446 // Max is a free data retrieval call binding the contract method 0x6ac5db19. 447 // 448 // Solidity: function max() view returns(uint256) 449 func (_Yweth *YwethCallerSession) Max() (*big.Int, error) { 450 return _Yweth.Contract.Max(&_Yweth.CallOpts) 451 } 452 453 // Min is a free data retrieval call binding the contract method 0xf8897945. 454 // 455 // Solidity: function min() view returns(uint256) 456 func (_Yweth *YwethCaller) Min(opts *bind.CallOpts) (*big.Int, error) { 457 var out []interface{} 458 err := _Yweth.contract.Call(opts, &out, "min") 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 // Min is a free data retrieval call binding the contract method 0xf8897945. 471 // 472 // Solidity: function min() view returns(uint256) 473 func (_Yweth *YwethSession) Min() (*big.Int, error) { 474 return _Yweth.Contract.Min(&_Yweth.CallOpts) 475 } 476 477 // Min is a free data retrieval call binding the contract method 0xf8897945. 478 // 479 // Solidity: function min() view returns(uint256) 480 func (_Yweth *YwethCallerSession) Min() (*big.Int, error) { 481 return _Yweth.Contract.Min(&_Yweth.CallOpts) 482 } 483 484 // Name is a free data retrieval call binding the contract method 0x06fdde03. 485 // 486 // Solidity: function name() view returns(string) 487 func (_Yweth *YwethCaller) Name(opts *bind.CallOpts) (string, error) { 488 var out []interface{} 489 err := _Yweth.contract.Call(opts, &out, "name") 490 491 if err != nil { 492 return *new(string), err 493 } 494 495 out0 := *abi.ConvertType(out[0], new(string)).(*string) 496 497 return out0, err 498 499 } 500 501 // Name is a free data retrieval call binding the contract method 0x06fdde03. 502 // 503 // Solidity: function name() view returns(string) 504 func (_Yweth *YwethSession) Name() (string, error) { 505 return _Yweth.Contract.Name(&_Yweth.CallOpts) 506 } 507 508 // Name is a free data retrieval call binding the contract method 0x06fdde03. 509 // 510 // Solidity: function name() view returns(string) 511 func (_Yweth *YwethCallerSession) Name() (string, error) { 512 return _Yweth.Contract.Name(&_Yweth.CallOpts) 513 } 514 515 // Symbol is a free data retrieval call binding the contract method 0x95d89b41. 516 // 517 // Solidity: function symbol() view returns(string) 518 func (_Yweth *YwethCaller) Symbol(opts *bind.CallOpts) (string, error) { 519 var out []interface{} 520 err := _Yweth.contract.Call(opts, &out, "symbol") 521 522 if err != nil { 523 return *new(string), err 524 } 525 526 out0 := *abi.ConvertType(out[0], new(string)).(*string) 527 528 return out0, err 529 530 } 531 532 // Symbol is a free data retrieval call binding the contract method 0x95d89b41. 533 // 534 // Solidity: function symbol() view returns(string) 535 func (_Yweth *YwethSession) Symbol() (string, error) { 536 return _Yweth.Contract.Symbol(&_Yweth.CallOpts) 537 } 538 539 // Symbol is a free data retrieval call binding the contract method 0x95d89b41. 540 // 541 // Solidity: function symbol() view returns(string) 542 func (_Yweth *YwethCallerSession) Symbol() (string, error) { 543 return _Yweth.Contract.Symbol(&_Yweth.CallOpts) 544 } 545 546 // Token is a free data retrieval call binding the contract method 0xfc0c546a. 547 // 548 // Solidity: function token() view returns(address) 549 func (_Yweth *YwethCaller) Token(opts *bind.CallOpts) (common.Address, error) { 550 var out []interface{} 551 err := _Yweth.contract.Call(opts, &out, "token") 552 553 if err != nil { 554 return *new(common.Address), err 555 } 556 557 out0 := *abi.ConvertType(out[0], new(common.Address)).(*common.Address) 558 559 return out0, err 560 561 } 562 563 // Token is a free data retrieval call binding the contract method 0xfc0c546a. 564 // 565 // Solidity: function token() view returns(address) 566 func (_Yweth *YwethSession) Token() (common.Address, error) { 567 return _Yweth.Contract.Token(&_Yweth.CallOpts) 568 } 569 570 // Token is a free data retrieval call binding the contract method 0xfc0c546a. 571 // 572 // Solidity: function token() view returns(address) 573 func (_Yweth *YwethCallerSession) Token() (common.Address, error) { 574 return _Yweth.Contract.Token(&_Yweth.CallOpts) 575 } 576 577 // TotalSupply is a free data retrieval call binding the contract method 0x18160ddd. 578 // 579 // Solidity: function totalSupply() view returns(uint256) 580 func (_Yweth *YwethCaller) TotalSupply(opts *bind.CallOpts) (*big.Int, error) { 581 var out []interface{} 582 err := _Yweth.contract.Call(opts, &out, "totalSupply") 583 584 if err != nil { 585 return *new(*big.Int), err 586 } 587 588 out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int) 589 590 return out0, err 591 592 } 593 594 // TotalSupply is a free data retrieval call binding the contract method 0x18160ddd. 595 // 596 // Solidity: function totalSupply() view returns(uint256) 597 func (_Yweth *YwethSession) TotalSupply() (*big.Int, error) { 598 return _Yweth.Contract.TotalSupply(&_Yweth.CallOpts) 599 } 600 601 // TotalSupply is a free data retrieval call binding the contract method 0x18160ddd. 602 // 603 // Solidity: function totalSupply() view returns(uint256) 604 func (_Yweth *YwethCallerSession) TotalSupply() (*big.Int, error) { 605 return _Yweth.Contract.TotalSupply(&_Yweth.CallOpts) 606 } 607 608 // Approve is a paid mutator transaction binding the contract method 0x095ea7b3. 609 // 610 // Solidity: function approve(address spender, uint256 amount) returns(bool) 611 func (_Yweth *YwethTransactor) Approve(opts *bind.TransactOpts, spender common.Address, amount *big.Int) (*types.Transaction, error) { 612 return _Yweth.contract.Transact(opts, "approve", spender, amount) 613 } 614 615 // Approve is a paid mutator transaction binding the contract method 0x095ea7b3. 616 // 617 // Solidity: function approve(address spender, uint256 amount) returns(bool) 618 func (_Yweth *YwethSession) Approve(spender common.Address, amount *big.Int) (*types.Transaction, error) { 619 return _Yweth.Contract.Approve(&_Yweth.TransactOpts, spender, amount) 620 } 621 622 // Approve is a paid mutator transaction binding the contract method 0x095ea7b3. 623 // 624 // Solidity: function approve(address spender, uint256 amount) returns(bool) 625 func (_Yweth *YwethTransactorSession) Approve(spender common.Address, amount *big.Int) (*types.Transaction, error) { 626 return _Yweth.Contract.Approve(&_Yweth.TransactOpts, spender, amount) 627 } 628 629 // DecreaseAllowance is a paid mutator transaction binding the contract method 0xa457c2d7. 630 // 631 // Solidity: function decreaseAllowance(address spender, uint256 subtractedValue) returns(bool) 632 func (_Yweth *YwethTransactor) DecreaseAllowance(opts *bind.TransactOpts, spender common.Address, subtractedValue *big.Int) (*types.Transaction, error) { 633 return _Yweth.contract.Transact(opts, "decreaseAllowance", spender, subtractedValue) 634 } 635 636 // DecreaseAllowance is a paid mutator transaction binding the contract method 0xa457c2d7. 637 // 638 // Solidity: function decreaseAllowance(address spender, uint256 subtractedValue) returns(bool) 639 func (_Yweth *YwethSession) DecreaseAllowance(spender common.Address, subtractedValue *big.Int) (*types.Transaction, error) { 640 return _Yweth.Contract.DecreaseAllowance(&_Yweth.TransactOpts, spender, subtractedValue) 641 } 642 643 // DecreaseAllowance is a paid mutator transaction binding the contract method 0xa457c2d7. 644 // 645 // Solidity: function decreaseAllowance(address spender, uint256 subtractedValue) returns(bool) 646 func (_Yweth *YwethTransactorSession) DecreaseAllowance(spender common.Address, subtractedValue *big.Int) (*types.Transaction, error) { 647 return _Yweth.Contract.DecreaseAllowance(&_Yweth.TransactOpts, spender, subtractedValue) 648 } 649 650 // Deposit is a paid mutator transaction binding the contract method 0xb6b55f25. 651 // 652 // Solidity: function deposit(uint256 _amount) returns() 653 func (_Yweth *YwethTransactor) Deposit(opts *bind.TransactOpts, _amount *big.Int) (*types.Transaction, error) { 654 return _Yweth.contract.Transact(opts, "deposit", _amount) 655 } 656 657 // Deposit is a paid mutator transaction binding the contract method 0xb6b55f25. 658 // 659 // Solidity: function deposit(uint256 _amount) returns() 660 func (_Yweth *YwethSession) Deposit(_amount *big.Int) (*types.Transaction, error) { 661 return _Yweth.Contract.Deposit(&_Yweth.TransactOpts, _amount) 662 } 663 664 // Deposit is a paid mutator transaction binding the contract method 0xb6b55f25. 665 // 666 // Solidity: function deposit(uint256 _amount) returns() 667 func (_Yweth *YwethTransactorSession) Deposit(_amount *big.Int) (*types.Transaction, error) { 668 return _Yweth.Contract.Deposit(&_Yweth.TransactOpts, _amount) 669 } 670 671 // DepositAll is a paid mutator transaction binding the contract method 0xde5f6268. 672 // 673 // Solidity: function depositAll() returns() 674 func (_Yweth *YwethTransactor) DepositAll(opts *bind.TransactOpts) (*types.Transaction, error) { 675 return _Yweth.contract.Transact(opts, "depositAll") 676 } 677 678 // DepositAll is a paid mutator transaction binding the contract method 0xde5f6268. 679 // 680 // Solidity: function depositAll() returns() 681 func (_Yweth *YwethSession) DepositAll() (*types.Transaction, error) { 682 return _Yweth.Contract.DepositAll(&_Yweth.TransactOpts) 683 } 684 685 // DepositAll is a paid mutator transaction binding the contract method 0xde5f6268. 686 // 687 // Solidity: function depositAll() returns() 688 func (_Yweth *YwethTransactorSession) DepositAll() (*types.Transaction, error) { 689 return _Yweth.Contract.DepositAll(&_Yweth.TransactOpts) 690 } 691 692 // DepositETH is a paid mutator transaction binding the contract method 0xf6326fb3. 693 // 694 // Solidity: function depositETH() payable returns() 695 func (_Yweth *YwethTransactor) DepositETH(opts *bind.TransactOpts) (*types.Transaction, error) { 696 return _Yweth.contract.Transact(opts, "depositETH") 697 } 698 699 // DepositETH is a paid mutator transaction binding the contract method 0xf6326fb3. 700 // 701 // Solidity: function depositETH() payable returns() 702 func (_Yweth *YwethSession) DepositETH() (*types.Transaction, error) { 703 return _Yweth.Contract.DepositETH(&_Yweth.TransactOpts) 704 } 705 706 // DepositETH is a paid mutator transaction binding the contract method 0xf6326fb3. 707 // 708 // Solidity: function depositETH() payable returns() 709 func (_Yweth *YwethTransactorSession) DepositETH() (*types.Transaction, error) { 710 return _Yweth.Contract.DepositETH(&_Yweth.TransactOpts) 711 } 712 713 // Earn is a paid mutator transaction binding the contract method 0xd389800f. 714 // 715 // Solidity: function earn() returns() 716 func (_Yweth *YwethTransactor) Earn(opts *bind.TransactOpts) (*types.Transaction, error) { 717 return _Yweth.contract.Transact(opts, "earn") 718 } 719 720 // Earn is a paid mutator transaction binding the contract method 0xd389800f. 721 // 722 // Solidity: function earn() returns() 723 func (_Yweth *YwethSession) Earn() (*types.Transaction, error) { 724 return _Yweth.Contract.Earn(&_Yweth.TransactOpts) 725 } 726 727 // Earn is a paid mutator transaction binding the contract method 0xd389800f. 728 // 729 // Solidity: function earn() returns() 730 func (_Yweth *YwethTransactorSession) Earn() (*types.Transaction, error) { 731 return _Yweth.Contract.Earn(&_Yweth.TransactOpts) 732 } 733 734 // Harvest is a paid mutator transaction binding the contract method 0x018ee9b7. 735 // 736 // Solidity: function harvest(address reserve, uint256 amount) returns() 737 func (_Yweth *YwethTransactor) Harvest(opts *bind.TransactOpts, reserve common.Address, amount *big.Int) (*types.Transaction, error) { 738 return _Yweth.contract.Transact(opts, "harvest", reserve, amount) 739 } 740 741 // Harvest is a paid mutator transaction binding the contract method 0x018ee9b7. 742 // 743 // Solidity: function harvest(address reserve, uint256 amount) returns() 744 func (_Yweth *YwethSession) Harvest(reserve common.Address, amount *big.Int) (*types.Transaction, error) { 745 return _Yweth.Contract.Harvest(&_Yweth.TransactOpts, reserve, amount) 746 } 747 748 // Harvest is a paid mutator transaction binding the contract method 0x018ee9b7. 749 // 750 // Solidity: function harvest(address reserve, uint256 amount) returns() 751 func (_Yweth *YwethTransactorSession) Harvest(reserve common.Address, amount *big.Int) (*types.Transaction, error) { 752 return _Yweth.Contract.Harvest(&_Yweth.TransactOpts, reserve, amount) 753 } 754 755 // IncreaseAllowance is a paid mutator transaction binding the contract method 0x39509351. 756 // 757 // Solidity: function increaseAllowance(address spender, uint256 addedValue) returns(bool) 758 func (_Yweth *YwethTransactor) IncreaseAllowance(opts *bind.TransactOpts, spender common.Address, addedValue *big.Int) (*types.Transaction, error) { 759 return _Yweth.contract.Transact(opts, "increaseAllowance", spender, addedValue) 760 } 761 762 // IncreaseAllowance is a paid mutator transaction binding the contract method 0x39509351. 763 // 764 // Solidity: function increaseAllowance(address spender, uint256 addedValue) returns(bool) 765 func (_Yweth *YwethSession) IncreaseAllowance(spender common.Address, addedValue *big.Int) (*types.Transaction, error) { 766 return _Yweth.Contract.IncreaseAllowance(&_Yweth.TransactOpts, spender, addedValue) 767 } 768 769 // IncreaseAllowance is a paid mutator transaction binding the contract method 0x39509351. 770 // 771 // Solidity: function increaseAllowance(address spender, uint256 addedValue) returns(bool) 772 func (_Yweth *YwethTransactorSession) IncreaseAllowance(spender common.Address, addedValue *big.Int) (*types.Transaction, error) { 773 return _Yweth.Contract.IncreaseAllowance(&_Yweth.TransactOpts, spender, addedValue) 774 } 775 776 // SetController is a paid mutator transaction binding the contract method 0x92eefe9b. 777 // 778 // Solidity: function setController(address _controller) returns() 779 func (_Yweth *YwethTransactor) SetController(opts *bind.TransactOpts, _controller common.Address) (*types.Transaction, error) { 780 return _Yweth.contract.Transact(opts, "setController", _controller) 781 } 782 783 // SetController is a paid mutator transaction binding the contract method 0x92eefe9b. 784 // 785 // Solidity: function setController(address _controller) returns() 786 func (_Yweth *YwethSession) SetController(_controller common.Address) (*types.Transaction, error) { 787 return _Yweth.Contract.SetController(&_Yweth.TransactOpts, _controller) 788 } 789 790 // SetController is a paid mutator transaction binding the contract method 0x92eefe9b. 791 // 792 // Solidity: function setController(address _controller) returns() 793 func (_Yweth *YwethTransactorSession) SetController(_controller common.Address) (*types.Transaction, error) { 794 return _Yweth.Contract.SetController(&_Yweth.TransactOpts, _controller) 795 } 796 797 // SetGovernance is a paid mutator transaction binding the contract method 0xab033ea9. 798 // 799 // Solidity: function setGovernance(address _governance) returns() 800 func (_Yweth *YwethTransactor) SetGovernance(opts *bind.TransactOpts, _governance common.Address) (*types.Transaction, error) { 801 return _Yweth.contract.Transact(opts, "setGovernance", _governance) 802 } 803 804 // SetGovernance is a paid mutator transaction binding the contract method 0xab033ea9. 805 // 806 // Solidity: function setGovernance(address _governance) returns() 807 func (_Yweth *YwethSession) SetGovernance(_governance common.Address) (*types.Transaction, error) { 808 return _Yweth.Contract.SetGovernance(&_Yweth.TransactOpts, _governance) 809 } 810 811 // SetGovernance is a paid mutator transaction binding the contract method 0xab033ea9. 812 // 813 // Solidity: function setGovernance(address _governance) returns() 814 func (_Yweth *YwethTransactorSession) SetGovernance(_governance common.Address) (*types.Transaction, error) { 815 return _Yweth.Contract.SetGovernance(&_Yweth.TransactOpts, _governance) 816 } 817 818 // SetMin is a paid mutator transaction binding the contract method 0x45dc3dd8. 819 // 820 // Solidity: function setMin(uint256 _min) returns() 821 func (_Yweth *YwethTransactor) SetMin(opts *bind.TransactOpts, _min *big.Int) (*types.Transaction, error) { 822 return _Yweth.contract.Transact(opts, "setMin", _min) 823 } 824 825 // SetMin is a paid mutator transaction binding the contract method 0x45dc3dd8. 826 // 827 // Solidity: function setMin(uint256 _min) returns() 828 func (_Yweth *YwethSession) SetMin(_min *big.Int) (*types.Transaction, error) { 829 return _Yweth.Contract.SetMin(&_Yweth.TransactOpts, _min) 830 } 831 832 // SetMin is a paid mutator transaction binding the contract method 0x45dc3dd8. 833 // 834 // Solidity: function setMin(uint256 _min) returns() 835 func (_Yweth *YwethTransactorSession) SetMin(_min *big.Int) (*types.Transaction, error) { 836 return _Yweth.Contract.SetMin(&_Yweth.TransactOpts, _min) 837 } 838 839 // Transfer is a paid mutator transaction binding the contract method 0xa9059cbb. 840 // 841 // Solidity: function transfer(address recipient, uint256 amount) returns(bool) 842 func (_Yweth *YwethTransactor) Transfer(opts *bind.TransactOpts, recipient common.Address, amount *big.Int) (*types.Transaction, error) { 843 return _Yweth.contract.Transact(opts, "transfer", recipient, amount) 844 } 845 846 // Transfer is a paid mutator transaction binding the contract method 0xa9059cbb. 847 // 848 // Solidity: function transfer(address recipient, uint256 amount) returns(bool) 849 func (_Yweth *YwethSession) Transfer(recipient common.Address, amount *big.Int) (*types.Transaction, error) { 850 return _Yweth.Contract.Transfer(&_Yweth.TransactOpts, recipient, amount) 851 } 852 853 // Transfer is a paid mutator transaction binding the contract method 0xa9059cbb. 854 // 855 // Solidity: function transfer(address recipient, uint256 amount) returns(bool) 856 func (_Yweth *YwethTransactorSession) Transfer(recipient common.Address, amount *big.Int) (*types.Transaction, error) { 857 return _Yweth.Contract.Transfer(&_Yweth.TransactOpts, recipient, amount) 858 } 859 860 // TransferFrom is a paid mutator transaction binding the contract method 0x23b872dd. 861 // 862 // Solidity: function transferFrom(address sender, address recipient, uint256 amount) returns(bool) 863 func (_Yweth *YwethTransactor) TransferFrom(opts *bind.TransactOpts, sender common.Address, recipient common.Address, amount *big.Int) (*types.Transaction, error) { 864 return _Yweth.contract.Transact(opts, "transferFrom", sender, recipient, amount) 865 } 866 867 // TransferFrom is a paid mutator transaction binding the contract method 0x23b872dd. 868 // 869 // Solidity: function transferFrom(address sender, address recipient, uint256 amount) returns(bool) 870 func (_Yweth *YwethSession) TransferFrom(sender common.Address, recipient common.Address, amount *big.Int) (*types.Transaction, error) { 871 return _Yweth.Contract.TransferFrom(&_Yweth.TransactOpts, sender, recipient, amount) 872 } 873 874 // TransferFrom is a paid mutator transaction binding the contract method 0x23b872dd. 875 // 876 // Solidity: function transferFrom(address sender, address recipient, uint256 amount) returns(bool) 877 func (_Yweth *YwethTransactorSession) TransferFrom(sender common.Address, recipient common.Address, amount *big.Int) (*types.Transaction, error) { 878 return _Yweth.Contract.TransferFrom(&_Yweth.TransactOpts, sender, recipient, amount) 879 } 880 881 // Withdraw is a paid mutator transaction binding the contract method 0x2e1a7d4d. 882 // 883 // Solidity: function withdraw(uint256 _shares) returns() 884 func (_Yweth *YwethTransactor) Withdraw(opts *bind.TransactOpts, _shares *big.Int) (*types.Transaction, error) { 885 return _Yweth.contract.Transact(opts, "withdraw", _shares) 886 } 887 888 // Withdraw is a paid mutator transaction binding the contract method 0x2e1a7d4d. 889 // 890 // Solidity: function withdraw(uint256 _shares) returns() 891 func (_Yweth *YwethSession) Withdraw(_shares *big.Int) (*types.Transaction, error) { 892 return _Yweth.Contract.Withdraw(&_Yweth.TransactOpts, _shares) 893 } 894 895 // Withdraw is a paid mutator transaction binding the contract method 0x2e1a7d4d. 896 // 897 // Solidity: function withdraw(uint256 _shares) returns() 898 func (_Yweth *YwethTransactorSession) Withdraw(_shares *big.Int) (*types.Transaction, error) { 899 return _Yweth.Contract.Withdraw(&_Yweth.TransactOpts, _shares) 900 } 901 902 // WithdrawAll is a paid mutator transaction binding the contract method 0x853828b6. 903 // 904 // Solidity: function withdrawAll() returns() 905 func (_Yweth *YwethTransactor) WithdrawAll(opts *bind.TransactOpts) (*types.Transaction, error) { 906 return _Yweth.contract.Transact(opts, "withdrawAll") 907 } 908 909 // WithdrawAll is a paid mutator transaction binding the contract method 0x853828b6. 910 // 911 // Solidity: function withdrawAll() returns() 912 func (_Yweth *YwethSession) WithdrawAll() (*types.Transaction, error) { 913 return _Yweth.Contract.WithdrawAll(&_Yweth.TransactOpts) 914 } 915 916 // WithdrawAll is a paid mutator transaction binding the contract method 0x853828b6. 917 // 918 // Solidity: function withdrawAll() returns() 919 func (_Yweth *YwethTransactorSession) WithdrawAll() (*types.Transaction, error) { 920 return _Yweth.Contract.WithdrawAll(&_Yweth.TransactOpts) 921 } 922 923 // WithdrawAllETH is a paid mutator transaction binding the contract method 0x90386bbf. 924 // 925 // Solidity: function withdrawAllETH() returns() 926 func (_Yweth *YwethTransactor) WithdrawAllETH(opts *bind.TransactOpts) (*types.Transaction, error) { 927 return _Yweth.contract.Transact(opts, "withdrawAllETH") 928 } 929 930 // WithdrawAllETH is a paid mutator transaction binding the contract method 0x90386bbf. 931 // 932 // Solidity: function withdrawAllETH() returns() 933 func (_Yweth *YwethSession) WithdrawAllETH() (*types.Transaction, error) { 934 return _Yweth.Contract.WithdrawAllETH(&_Yweth.TransactOpts) 935 } 936 937 // WithdrawAllETH is a paid mutator transaction binding the contract method 0x90386bbf. 938 // 939 // Solidity: function withdrawAllETH() returns() 940 func (_Yweth *YwethTransactorSession) WithdrawAllETH() (*types.Transaction, error) { 941 return _Yweth.Contract.WithdrawAllETH(&_Yweth.TransactOpts) 942 } 943 944 // WithdrawETH is a paid mutator transaction binding the contract method 0xf14210a6. 945 // 946 // Solidity: function withdrawETH(uint256 _shares) returns() 947 func (_Yweth *YwethTransactor) WithdrawETH(opts *bind.TransactOpts, _shares *big.Int) (*types.Transaction, error) { 948 return _Yweth.contract.Transact(opts, "withdrawETH", _shares) 949 } 950 951 // WithdrawETH is a paid mutator transaction binding the contract method 0xf14210a6. 952 // 953 // Solidity: function withdrawETH(uint256 _shares) returns() 954 func (_Yweth *YwethSession) WithdrawETH(_shares *big.Int) (*types.Transaction, error) { 955 return _Yweth.Contract.WithdrawETH(&_Yweth.TransactOpts, _shares) 956 } 957 958 // WithdrawETH is a paid mutator transaction binding the contract method 0xf14210a6. 959 // 960 // Solidity: function withdrawETH(uint256 _shares) returns() 961 func (_Yweth *YwethTransactorSession) WithdrawETH(_shares *big.Int) (*types.Transaction, error) { 962 return _Yweth.Contract.WithdrawETH(&_Yweth.TransactOpts, _shares) 963 } 964 965 // Fallback is a paid mutator transaction binding the contract fallback function. 966 // 967 // Solidity: fallback() payable returns() 968 func (_Yweth *YwethTransactor) Fallback(opts *bind.TransactOpts, calldata []byte) (*types.Transaction, error) { 969 return _Yweth.contract.RawTransact(opts, calldata) 970 } 971 972 // Fallback is a paid mutator transaction binding the contract fallback function. 973 // 974 // Solidity: fallback() payable returns() 975 func (_Yweth *YwethSession) Fallback(calldata []byte) (*types.Transaction, error) { 976 return _Yweth.Contract.Fallback(&_Yweth.TransactOpts, calldata) 977 } 978 979 // Fallback is a paid mutator transaction binding the contract fallback function. 980 // 981 // Solidity: fallback() payable returns() 982 func (_Yweth *YwethTransactorSession) Fallback(calldata []byte) (*types.Transaction, error) { 983 return _Yweth.Contract.Fallback(&_Yweth.TransactOpts, calldata) 984 } 985 986 // YwethApprovalIterator is returned from FilterApproval and is used to iterate over the raw logs and unpacked data for Approval events raised by the Yweth contract. 987 type YwethApprovalIterator struct { 988 Event *YwethApproval // Event containing the contract specifics and raw log 989 990 contract *bind.BoundContract // Generic contract to use for unpacking event data 991 event string // Event name to use for unpacking event data 992 993 logs chan types.Log // Log channel receiving the found contract events 994 sub ethereum.Subscription // Subscription for errors, completion and termination 995 done bool // Whether the subscription completed delivering logs 996 fail error // Occurred error to stop iteration 997 } 998 999 // Next advances the iterator to the subsequent event, returning whether there 1000 // are any more events found. In case of a retrieval or parsing error, false is 1001 // returned and Error() can be queried for the exact failure. 1002 func (it *YwethApprovalIterator) Next() bool { 1003 // If the iterator failed, stop iterating 1004 if it.fail != nil { 1005 return false 1006 } 1007 // If the iterator completed, deliver directly whatever's available 1008 if it.done { 1009 select { 1010 case log := <-it.logs: 1011 it.Event = new(YwethApproval) 1012 if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { 1013 it.fail = err 1014 return false 1015 } 1016 it.Event.Raw = log 1017 return true 1018 1019 default: 1020 return false 1021 } 1022 } 1023 // Iterator still in progress, wait for either a data or an error event 1024 select { 1025 case log := <-it.logs: 1026 it.Event = new(YwethApproval) 1027 if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { 1028 it.fail = err 1029 return false 1030 } 1031 it.Event.Raw = log 1032 return true 1033 1034 case err := <-it.sub.Err(): 1035 it.done = true 1036 it.fail = err 1037 return it.Next() 1038 } 1039 } 1040 1041 // Error returns any retrieval or parsing error occurred during filtering. 1042 func (it *YwethApprovalIterator) Error() error { 1043 return it.fail 1044 } 1045 1046 // Close terminates the iteration process, releasing any pending underlying 1047 // resources. 1048 func (it *YwethApprovalIterator) Close() error { 1049 it.sub.Unsubscribe() 1050 return nil 1051 } 1052 1053 // YwethApproval represents a Approval event raised by the Yweth contract. 1054 type YwethApproval struct { 1055 Owner common.Address 1056 Spender common.Address 1057 Value *big.Int 1058 Raw types.Log // Blockchain specific contextual infos 1059 } 1060 1061 // FilterApproval is a free log retrieval operation binding the contract event 0x8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925. 1062 // 1063 // Solidity: event Approval(address indexed owner, address indexed spender, uint256 value) 1064 func (_Yweth *YwethFilterer) FilterApproval(opts *bind.FilterOpts, owner []common.Address, spender []common.Address) (*YwethApprovalIterator, error) { 1065 1066 var ownerRule []interface{} 1067 for _, ownerItem := range owner { 1068 ownerRule = append(ownerRule, ownerItem) 1069 } 1070 var spenderRule []interface{} 1071 for _, spenderItem := range spender { 1072 spenderRule = append(spenderRule, spenderItem) 1073 } 1074 1075 logs, sub, err := _Yweth.contract.FilterLogs(opts, "Approval", ownerRule, spenderRule) 1076 if err != nil { 1077 return nil, err 1078 } 1079 return &YwethApprovalIterator{contract: _Yweth.contract, event: "Approval", logs: logs, sub: sub}, nil 1080 } 1081 1082 // WatchApproval is a free log subscription operation binding the contract event 0x8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925. 1083 // 1084 // Solidity: event Approval(address indexed owner, address indexed spender, uint256 value) 1085 func (_Yweth *YwethFilterer) WatchApproval(opts *bind.WatchOpts, sink chan<- *YwethApproval, owner []common.Address, spender []common.Address) (event.Subscription, error) { 1086 1087 var ownerRule []interface{} 1088 for _, ownerItem := range owner { 1089 ownerRule = append(ownerRule, ownerItem) 1090 } 1091 var spenderRule []interface{} 1092 for _, spenderItem := range spender { 1093 spenderRule = append(spenderRule, spenderItem) 1094 } 1095 1096 logs, sub, err := _Yweth.contract.WatchLogs(opts, "Approval", ownerRule, spenderRule) 1097 if err != nil { 1098 return nil, err 1099 } 1100 return event.NewSubscription(func(quit <-chan struct{}) error { 1101 defer sub.Unsubscribe() 1102 for { 1103 select { 1104 case log := <-logs: 1105 // New log arrived, parse the event and forward to the user 1106 event := new(YwethApproval) 1107 if err := _Yweth.contract.UnpackLog(event, "Approval", log); err != nil { 1108 return err 1109 } 1110 event.Raw = log 1111 1112 select { 1113 case sink <- event: 1114 case err := <-sub.Err(): 1115 return err 1116 case <-quit: 1117 return nil 1118 } 1119 case err := <-sub.Err(): 1120 return err 1121 case <-quit: 1122 return nil 1123 } 1124 } 1125 }), nil 1126 } 1127 1128 // ParseApproval is a log parse operation binding the contract event 0x8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925. 1129 // 1130 // Solidity: event Approval(address indexed owner, address indexed spender, uint256 value) 1131 func (_Yweth *YwethFilterer) ParseApproval(log types.Log) (*YwethApproval, error) { 1132 event := new(YwethApproval) 1133 if err := _Yweth.contract.UnpackLog(event, "Approval", log); err != nil { 1134 return nil, err 1135 } 1136 return event, nil 1137 } 1138 1139 // YwethTransferIterator is returned from FilterTransfer and is used to iterate over the raw logs and unpacked data for Transfer events raised by the Yweth contract. 1140 type YwethTransferIterator struct { 1141 Event *YwethTransfer // Event containing the contract specifics and raw log 1142 1143 contract *bind.BoundContract // Generic contract to use for unpacking event data 1144 event string // Event name to use for unpacking event data 1145 1146 logs chan types.Log // Log channel receiving the found contract events 1147 sub ethereum.Subscription // Subscription for errors, completion and termination 1148 done bool // Whether the subscription completed delivering logs 1149 fail error // Occurred error to stop iteration 1150 } 1151 1152 // Next advances the iterator to the subsequent event, returning whether there 1153 // are any more events found. In case of a retrieval or parsing error, false is 1154 // returned and Error() can be queried for the exact failure. 1155 func (it *YwethTransferIterator) Next() bool { 1156 // If the iterator failed, stop iterating 1157 if it.fail != nil { 1158 return false 1159 } 1160 // If the iterator completed, deliver directly whatever's available 1161 if it.done { 1162 select { 1163 case log := <-it.logs: 1164 it.Event = new(YwethTransfer) 1165 if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { 1166 it.fail = err 1167 return false 1168 } 1169 it.Event.Raw = log 1170 return true 1171 1172 default: 1173 return false 1174 } 1175 } 1176 // Iterator still in progress, wait for either a data or an error event 1177 select { 1178 case log := <-it.logs: 1179 it.Event = new(YwethTransfer) 1180 if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { 1181 it.fail = err 1182 return false 1183 } 1184 it.Event.Raw = log 1185 return true 1186 1187 case err := <-it.sub.Err(): 1188 it.done = true 1189 it.fail = err 1190 return it.Next() 1191 } 1192 } 1193 1194 // Error returns any retrieval or parsing error occurred during filtering. 1195 func (it *YwethTransferIterator) Error() error { 1196 return it.fail 1197 } 1198 1199 // Close terminates the iteration process, releasing any pending underlying 1200 // resources. 1201 func (it *YwethTransferIterator) Close() error { 1202 it.sub.Unsubscribe() 1203 return nil 1204 } 1205 1206 // YwethTransfer represents a Transfer event raised by the Yweth contract. 1207 type YwethTransfer struct { 1208 From common.Address 1209 To common.Address 1210 Value *big.Int 1211 Raw types.Log // Blockchain specific contextual infos 1212 } 1213 1214 // FilterTransfer is a free log retrieval operation binding the contract event 0xddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef. 1215 // 1216 // Solidity: event Transfer(address indexed from, address indexed to, uint256 value) 1217 func (_Yweth *YwethFilterer) FilterTransfer(opts *bind.FilterOpts, from []common.Address, to []common.Address) (*YwethTransferIterator, error) { 1218 1219 var fromRule []interface{} 1220 for _, fromItem := range from { 1221 fromRule = append(fromRule, fromItem) 1222 } 1223 var toRule []interface{} 1224 for _, toItem := range to { 1225 toRule = append(toRule, toItem) 1226 } 1227 1228 logs, sub, err := _Yweth.contract.FilterLogs(opts, "Transfer", fromRule, toRule) 1229 if err != nil { 1230 return nil, err 1231 } 1232 return &YwethTransferIterator{contract: _Yweth.contract, event: "Transfer", logs: logs, sub: sub}, nil 1233 } 1234 1235 // WatchTransfer is a free log subscription operation binding the contract event 0xddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef. 1236 // 1237 // Solidity: event Transfer(address indexed from, address indexed to, uint256 value) 1238 func (_Yweth *YwethFilterer) WatchTransfer(opts *bind.WatchOpts, sink chan<- *YwethTransfer, from []common.Address, to []common.Address) (event.Subscription, error) { 1239 1240 var fromRule []interface{} 1241 for _, fromItem := range from { 1242 fromRule = append(fromRule, fromItem) 1243 } 1244 var toRule []interface{} 1245 for _, toItem := range to { 1246 toRule = append(toRule, toItem) 1247 } 1248 1249 logs, sub, err := _Yweth.contract.WatchLogs(opts, "Transfer", fromRule, toRule) 1250 if err != nil { 1251 return nil, err 1252 } 1253 return event.NewSubscription(func(quit <-chan struct{}) error { 1254 defer sub.Unsubscribe() 1255 for { 1256 select { 1257 case log := <-logs: 1258 // New log arrived, parse the event and forward to the user 1259 event := new(YwethTransfer) 1260 if err := _Yweth.contract.UnpackLog(event, "Transfer", log); err != nil { 1261 return err 1262 } 1263 event.Raw = log 1264 1265 select { 1266 case sink <- event: 1267 case err := <-sub.Err(): 1268 return err 1269 case <-quit: 1270 return nil 1271 } 1272 case err := <-sub.Err(): 1273 return err 1274 case <-quit: 1275 return nil 1276 } 1277 } 1278 }), nil 1279 } 1280 1281 // ParseTransfer is a log parse operation binding the contract event 0xddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef. 1282 // 1283 // Solidity: event Transfer(address indexed from, address indexed to, uint256 value) 1284 func (_Yweth *YwethFilterer) ParseTransfer(log types.Log) (*YwethTransfer, error) { 1285 event := new(YwethTransfer) 1286 if err := _Yweth.contract.UnpackLog(event, "Transfer", log); err != nil { 1287 return nil, err 1288 } 1289 return event, nil 1290 }