Skip to main content

YearnYielder

Git Source

Inherits: IYielder, Ownable

State Variables

wethVault

IyVaultV2 public wethVault = IyVaultV2(0xa9fE4601811213c340e850ea305481afF02f5b28);

weth

address public weth;

deposited

uint256 public override deposited = 0;

decimals

uint256 public decimals;

Functions

constructor

constructor(address _weth);

getCurrentBalance

function getCurrentBalance() public view override returns (uint256);

deposit

function deposit() external payable override onlyOwner;

withdraw

function withdraw(uint256 _amount, address payable _beneficiary) public override onlyOwner;

withdrawAll

function withdrawAll(address payable _beneficiary) external override onlyOwner returns (uint256 _balance);

updateApproval

Updates the vaults approval of the token to be the maximum value.

function updateApproval() public;

_sharesToTokens

Computes the number of tokens an amount of shares is worth.

function _sharesToTokens(uint256 _sharesAmount) private view returns (uint256);

Parameters

NameTypeDescription
_sharesAmountuint256the amount of shares.

Returns

NameTypeDescription
<none>uint256the number of tokens the shares are worth.

_tokensToShares

Computes the number of shares an amount of tokens is worth.

function _tokensToShares(uint256 _tokensAmount) private view returns (uint256);

Parameters

NameTypeDescription
_tokensAmountuint256the amount of shares.

Returns

NameTypeDescription
<none>uint256the number of shares the tokens are worth.