PoolAddressesProvider
Inherits: Adminable, IPoolAddressesProvider
State Variables
_marketId
_addresses
POOL
POOL_CONFIGURATOR
ISLE_GLOBALS
LOAN_MANAGER
WITHDRAWAL_MANAGER
Functions
constructor
getMarketId
setMarketId
getPoolConfigurator
Returns the address of the PoolConfigurator proxy.
Returns
Name | Type | Description |
---|---|---|
|
| The PoolConfigurator proxy address |
setPoolConfiguratorImpl
Updates the implementation of the PoolConfigurator, or creates a proxy setting the new PoolConfigurator
implementation when the function is called for the first time.
Parameters
Name | Type | Description |
---|---|---|
|
| The new PoolConfigurator implementation |
|
|
getLoanManager
Returns the address of the LoanManager proxy.
Returns
Name | Type | Description |
---|---|---|
|
| The LoanManager proxy address |
setLoanManagerImpl
Updates the implementation of the LoanManager, or creates a proxy setting the new LoanManager
implementation when the function is called for the first time.
Parameters
Name | Type | Description |
---|---|---|
|
| The new LoanManager implementation |
getWithdrawalManager
Returns the address of the WithdrawalManager proxy.
Returns
Name | Type | Description |
---|---|---|
|
| The WithdrawalManager proxy address |
setWithdrawalManagerImpl
Updates the implementation of the WithdrawalManager, or creates a proxy setting the new WithdrawalManager
implementation when the function is called for the first time.
Parameters
Name | Type | Description |
---|---|---|
|
| The new WithdrawalManager implementation |
|
|
setAddressAsProxy
General function to update the implementation of a proxy registered with certain id
. If there is no proxy registered, it will instantiate one and set as implementation the newImplementationAddress
.
IMPORTANT Use this function carefully, only for ids that don't have an explicit setter function, in order to avoid unexpected consequences
Parameters
Name | Type | Description |
---|---|---|
|
| The id |
|
| The address of the new implementation |
|
| The intialization parameters for the proxied contract |
getIsleGlobals
Returns the address of isle globals.
Returns
Name | Type | Description |
---|---|---|
|
| The IsleGlobals address |
setIsleGlobals
Sets an address for IsleGlobals replacing the address saved in the addresses map
Parameters
Name | Type | Description |
---|---|---|
|
| IsleGlobals address |
getAddress
Returns an address by its identifier.
The returned address might be an EOA or a contract, potentially proxied
Parameters
Name | Type | Description |
---|---|---|
|
| The id |
Returns
Name | Type | Description |
---|---|---|
|
| The address of the registered for the specified id |
setAddress
Sets an address for an id replacing the address saved in the addresses map.
IMPORTANT Use this function carefully, as it will do a hard replacement
Parameters
Name | Type | Description |
---|---|---|
|
| The id |
|
| The address to set |
_updateImpl
Internal function to update the implementation of a specific proxied component of the protocol.
If there is no proxy registered with the given identifier, it creates the proxy setting newAddress
as implementation and calls the initialize() function on the proxy
If there is already a proxy registered, it just updates the implementation to newAddress
and calls the initialize() function via upgradeToAndCall() in the proxy
Parameters
Name | Type | Description |
---|---|---|
|
| The id of the proxy to be updated |
|
| The address of the new implementation |
_updateImpl
_setMarketId
Updates the identifier of the Isle market.
Parameters
Name | Type | Description |
---|---|---|
|
| The new id of the market |
_getProxyImplementation
Returns the the implementation contract of the proxy contract by its identifier.
It returns ZERO if there is no registered address with the given id
It reverts if the registered address with the given id is not InitializableImmutableAdminUpgradeabilityProxy
Parameters
Name | Type | Description |
---|---|---|
|
| The id |
Returns
Name | Type | Description |
---|---|---|
|
| The address of the implementation contract |
Last updated