ILPWhitelist
Types
Operation
Enum of the operations that can be checked against the whitelist
enum Operation {
deposit,
withdraw,
sendTransfer,
receiveTransfer
}
Public Functions
acceptsOperation
function acceptsOperation(contract IEToken etoken, address provider, enum ILPWhitelist.Operation operation) external view returns (bool)
Returns whether provider is allowed to perform operation on etoken.
Parameters
| Name |
Type |
Description |
| etoken |
contract IEToken |
The eToken context. |
| provider |
address |
The address of the liquidity provider. |
| operation |
enum ILPWhitelist.Operation |
The operation to check. |
Return Values
| Name |
Type |
Description |
| [0] |
bool |
true if the operation is accepted, false otherwise. |
acceptsDeposit
function acceptsDeposit(contract IEToken etoken, address provider, uint256 amount) external view returns (bool)
Indicates whether or not a liquidity provider can do a deposit in an eToken.
Parameters
| Name |
Type |
Description |
| etoken |
contract IEToken |
The eToken (see {EToken}) where the provider wants to deposit money. |
| provider |
address |
The address of the liquidity provider (user) that wants to deposit |
| amount |
uint256 |
The amount of the deposit |
Return Values
| Name |
Type |
Description |
| [0] |
bool |
true if provider deposit is accepted, false if not |
acceptsTransfer
function acceptsTransfer(contract IEToken etoken, address providerFrom, address providerTo, uint256 amount) external view returns (bool)
Indicates whether or not the eTokens can be transferred from providerFrom to providerTo
Parameters
| Name |
Type |
Description |
| etoken |
contract IEToken |
The eToken (see {EToken}) that the LPs have the intention to transfer. |
| providerFrom |
address |
The current owner of the tokens |
| providerTo |
address |
The destination of the tokens if the transfer is accepted |
| amount |
uint256 |
The amount of tokens to be transferred |
Return Values
| Name |
Type |
Description |
| [0] |
bool |
true if the transfer operation is accepted, false if not. |
acceptsWithdrawal
function acceptsWithdrawal(contract IEToken etoken, address provider, uint256 amount) external view returns (bool)
Indicates whether or not a liquidity provider can withdraw an eToken.
Parameters
| Name |
Type |
Description |
| etoken |
contract IEToken |
The eToken (see {EToken}) where the provider wants to withdraw money. |
| provider |
address |
The address of the liquidity provider (user) that wants to withdraw |
| amount |
uint256 |
The amount of the withdrawal |
Return Values
| Name |
Type |
Description |
| [0] |
bool |
true if provider withdraw request is accepted, false if not |