VaultConfigurator
Methods
DELEGATOR_FACTORY
function DELEGATOR_FACTORY() external view returns (address)
Get the delegator factory’s address.
Returns
Name | Type | Description |
---|---|---|
address | address of the delegator factory |
SLASHER_FACTORY
function SLASHER_FACTORY() external view returns (address)
Get the slasher factory’s address.
Returns
Name | Type | Description |
---|---|---|
address | address of the slasher factory |
VAULT_FACTORY
function VAULT_FACTORY() external view returns (address)
Get the vault factory’s address.
Returns
Name | Type | Description |
---|---|---|
address | address of the vault factory |
create
function create(InitParams params) external nonpayable returns (address vault, address delegator, address slasher)
Create a new vault with a delegator and a slasher.
Parameters
Name | Type | Description |
---|---|---|
params | InitParams | initial parameters needed for a vault with a delegator and a slasher deployment |
Returns
Name | Type | Description |
---|---|---|
vault | address | address of the vault |
delegator | address | address of the delegator |
slasher | address | address of the slasher |
Structs
InitParams
struct InitParams {
uint64 version;
address owner;
bytes vaultParams;
uint64 delegatorIndex;
bytes delegatorParams;
bool withSlasher;
uint64 slasherIndex;
bytes slasherParams;
}
Initial parameters needed for a vault with a delegator and a slasher deployment.
Parameters
Name | Type | Description |
---|---|---|
version | uint64 | entity’s version to use |
owner | address | initial owner of the entity |
vaultParams | bytes | parameters for the vault initialization |
delegatorIndex | uint64 | delegator’s index of the implementation to deploy |
delegatorParams | bytes | parameters for the delegator initialization |
withSlasher | bool | whether to deploy a slasher or not |
slasherIndex | uint64 | slasher’s index of the implementation to deploy (used only if withSlasher == true) |
slasherParams | bytes | parameters for the slasher initialization (used only if withSlasher == true) |