IModuleRegistry
Author: Arrakis Team.
interface of module registry that contains all whitelisted modules.
Functions
beacons
function to get the whitelisted list of IBeacon that have module as implementation.
function beacons() external view returns (address[] memory beacons);
Returns
Name | Type | Description |
---|---|---|
beacons | address[] | list of upgradeable beacon. |
beaconsContains
function to know if the beacons enumerableSet contain beacon_
function beaconsContains(address beacon_)
external
view
returns (bool isContained);
Parameters
Name | Type | Description |
---|---|---|
beacon_ | address | beacon address to check |
guardian
function used to get the guardian address of arrakis protocol.
function guardian() external view returns (address);
Returns
Name | Type | Description |
---|---|---|
<none> | address | guardian address of the pauser. |
admin
function used to get the admin address that can upgrade beacon implementation.
admin address should be a timelock contract.
function admin() external view returns (address);
Returns
Name | Type | Description |
---|---|---|
<none> | address | admin address that can upgrade beacon implementation. |
initialize
function used to initialize module registry.
function initialize(address factory_) external;
Parameters
Name | Type | Description |
---|---|---|
factory_ | address | address of ArrakisMetaVaultFactory, who is the only one who can call the init management function. |
whitelistBeacons
function used to whitelist IBeacon that contain implementation of valid module.
function whitelistBeacons(address[] calldata beacons_) external;
Parameters
Name | Type | Description |
---|---|---|
beacons_ | address[] | list of beacon to whitelist. |
blacklistBeacons
function used to blacklist IBeacon that contain implementation of unvalid (from now) module.
function blacklistBeacons(address[] calldata beacons_) external;
Parameters
Name | Type | Description |
---|---|---|
beacons_ | address[] | list of beacon to blacklist. |
createModule
function used to create module instance that can be whitelisted as module inside a vault.
function createModule(
address vault_,
address beacon_,
bytes calldata payload_
) external returns (address module);
Parameters
Name | Type | Description |
---|---|---|
vault_ | address | |
beacon_ | address | which whitelisted beacon's implementation we want to create an instance of. |
payload_ | bytes | payload to create the module. |
Events
LogWhitelistBeacons
Log whitelist action of beacons.
event LogWhitelistBeacons(address[] beacons);
Parameters
Name | Type | Description |
---|---|---|
beacons | address[] | list of beacons whitelisted. |
LogBlacklistBeacons
Log blacklist action of beacons.
event LogBlacklistBeacons(address[] beacons);
Parameters
Name | Type | Description |
---|---|---|
beacons | address[] | list of beacons blacklisted. |
Errors
AddressZero
error AddressZero();
AlreadyWhitelistedBeacon
error AlreadyWhitelistedBeacon(address beacon);
NotAlreadyWhitelistedBeacon
error NotAlreadyWhitelistedBeacon(address beacon);
NotWhitelistedBeacon
error NotWhitelistedBeacon();
NotBeacon
error NotBeacon();
ModuleNotLinkedToMetaVault
error ModuleNotLinkedToMetaVault();
NotSameGuardian
error NotSameGuardian();
NotSameAdmin
error NotSameAdmin();