UniversalLending
Inherits: AaveLending, CompoundV3Lending, CompoundV2Lending, MorphoLending, SiloV2Lending, DeltaErrors
Merge all lending ops in one operation Can inject parameters
- paramPush for receiving funds (e.g. receiving funds from swaps or flash loans)
- paramPull for being required to pay an exact amount (e.g. DEX swap payments, flash loan amounts)
Functions
_lendingOperations
Executes any lending operation across various lenders
Routes to appropriate lender based on operation and lender ID
Note: calldata-offset-table:
| Offset | Length (bytes) | Description |
|---|---|---|
| 0 | 1 | lendingOperation |
| 1 | 2 | lender |
| 3 | variable | rest |
function _lendingOperations(
address callerAddress,
uint256 currentOffset // params similar to deltaComposeInternal
)
internal
returns (uint256);
Parameters
| Name | Type | Description |
|---|---|---|
callerAddress |
address |
Address of the caller |
currentOffset |
uint256 |
Current position in the calldata |
Returns
| Name | Type | Description |
|---|---|---|
<none> |
uint256 |
Updated calldata offset after processing |