VaultFactoryDeploymentCore ​
Inherits:VaultFactoryCore, VaultFactoryAuth
implements VaultFactory deploy vault related helpers.
Functions ​
_deploy ​
Deploys a contract using the CREATE opcode with the provided bytecode (bytecode_). This is an internal function, meant to be used within the contract to facilitate the deployment of other contracts.
solidity
function _deploy(bytes memory bytecode_) internal returns (address address_);Parameters
| Name | Type | Description |
|---|---|---|
bytecode_ | bytes | The bytecode of the contract to be deployed. |
Returns
| Name | Type | Description |
|---|---|---|
address_ | address | Returns the address of the deployed contract. |
_deployVaultStart ​
solidity
function _deployVaultStart(address vaultDeploymentLogic_) internal returns (address vault_, uint256 vaultId_);_deployVaultFinalize ​
solidity
function _deployVaultFinalize(address vault_, uint256 vaultId_, bool success_, bytes memory data_) internal;getVaultAddress ​
Computes the address of a vault based on its given ID (vaultId_).
solidity
function getVaultAddress(uint256 vaultId_) public view returns (address vault_);Parameters
| Name | Type | Description |
|---|---|---|
vaultId_ | uint256 | The ID of the vault. |
Returns
| Name | Type | Description |
|---|---|---|
vault_ | address | Returns the computed address of the vault. |
isVault ​
Checks if a given address (vault_) corresponds to a valid vault.
solidity
function isVault(address vault_) public view returns (bool);Parameters
| Name | Type | Description |
|---|---|---|
vault_ | address | The vault address to check. |
Returns
| Name | Type | Description |
|---|---|---|
<none> | bool | Returns true if the given address corresponds to a valid vault, otherwise false. |
totalVaults ​
Returns the total number of vaults deployed by the factory.
solidity
function totalVaults() external view returns (uint256);Returns
| Name | Type | Description |
|---|---|---|
<none> | uint256 | Returns the total number of vaults. |