Relevant view functions
There are a few view functions that can be useful to the user.
function getVaultBalance() public virtual view returns(uint256)
Gives the balance of the vault (all deposits - withdrawals + liquidityPerc
). The balance is the maximum what a user can withdraw without pulling funds from the underlying protocols.
savedTotalUnderlying()
The total amount of funds in the underlying protocols. Together with the balanceOf()
this defines the maximum what a user can withdraw when also pulling from the underlying protocols. If a user wishes to withdraw more it should do so via a withdrawalRequest
.
exchangeRate()
Defines the exchangeRate in vaultCurrency per LP token in the scale of the vaultCurrency. For example USDC/LPtoken with 6 decimals of scale (like USDC).
Last updated