AlphaProVaultFactory
The contract that creates liquidity vaults.
createVault
Creates a vault for a given set of vault parameters.
Parameters:
Varible | Type | Description |
---|---|---|
| VaultParams | The custom data structure containing the Vault Parameters' variables and assigned values. |
Returns:
Variable | Type | Description |
---|---|---|
| address | The address of the new vault after it is created. |
numVaults
Return Value:
Variable | Type | Description |
---|---|---|
| uint256 | The number of vaults created by the factory. |
setProtocolFee
Sets the protocol fee as a % of fees received from Uniswap. Can only be called by Charm Governance.
Parameters:
Variale | Type | Description |
---|---|---|
uint256 | The amount of protocol fees as a % of fees earned by the vault, with 1 unit of fees = 1e-4 % of fees earned. The maximum protocol fee is 20000 units (20%). |
setGovernance
The first step to change the address of Charm Governance. Can only called by Charm Governance.
Parameters:
Variable | Type | Description |
---|---|---|
address | The new address of Charm Governance. The changes will not take effect until the new address calls |
acceptGovernance
The second step to to change the address of Charm Governance. Can only be called by the address assigned to _governance
.
State Changes:
Variable | Type | Description |
---|---|---|
| address | Setting the value of |
Getter functions for public variables
Getter functions are automatically generated for the following public variables:
Variable | Type | Description |
---|---|---|
| address | The address of the template vault used by createVault to clone and create LP vaults. |
| array | The array that contains the address of all the vaults created by Alpha Vaults. |
| mapping | The mapping used to check whether a vault have been created by Alpha Vaults. |
| address | The address of Charm Governance. |
| address | The provisional address of Charm Governance. Not finalised until it calls calls |
| uint256 | The protocol fee applied to all vaults created using Alpha Vaults. |
Last updated