AaveLendingPoolAssetGuard
Functions:
Function constructor(address _aaveProtocolDataProvider)
constructor(address _aaveProtocolDataProvider)
No description
Function getBalance(address pool, address) → uint256 balance
getBalance(address pool, address) → uint256 balance
Returns the pool position of Aave lending pool
Parameters:
pool
: The pool logic address
Return Values:
balance The total balance of the pool
Function getDecimals(address) → uint256 decimals
getDecimals(address) → uint256 decimals
Returns decimal of the Aave lending pool asset
Function withdrawProcessing(address pool, address, uint256 portion, address to) → address withdrawAsset, uint256 withdrawBalance, struct IAssetGuard.MultiTransaction[] transactions
withdrawProcessing(address pool, address, uint256 portion, address to) → address withdrawAsset, uint256 withdrawBalance, struct IAssetGuard.MultiTransaction[] transactions
Creates transaction data for withdrawing tokens
Return Values:
withdrawAsset and
withdrawBalance are used to withdraw portion of asset balance to investor
transactions is used to execute the withdrawal transaction in PoolLogic
Function flashloanProcessing(address pool, uint256 portion, address[] repayAssets, uint256[] repayAmounts, uint256[] premiums, uint256[] interestRateModes) → struct IAssetGuard.MultiTransaction[] transactions
flashloanProcessing(address pool, uint256 portion, address[] repayAssets, uint256[] repayAmounts, uint256[] premiums, uint256[] interestRateModes) → struct IAssetGuard.MultiTransaction[] transactions
process flash loan and return the transactions for execution
Parameters:
pool
: the PoolLogic addressportion
: the portion of assets to be withdrawnrepayAssets
: Array of assets to be repaidrepayAmounts
: Array of amounts to be repaidpremiums
: Array of premiums to be paid for flash loaninterestRateModes
: Array of interest rate modes of the debts
Return Values:
transactions Array of transactions to be executed
Last updated