AeraVaultModulesFactory

AeraVaultModulesFactory

Inherits: IAeraVaultAssetRegistryFactory, IAeraVaultHooksFactory, Sweepable

Used to create new asset registry and hooks.

Only one instance of the factory will be required per chain.

State Variables

v2Factory

The address of the v2 factory.

address public immutable v2Factory;

wrappedNativeToken

Wrapped native token.

IERC20 public immutable wrappedNativeToken;

Functions

onlyOwnerOrV2Factory

MODIFIERS ///

Throws if called by any account other than the owner or v2 factory.

modifier onlyOwnerOrV2Factory();

constructor

FUNCTIONS ///

constructor(address v2Factory_) Ownable;

deployAssetRegistry

Deploy asset registry.

function deployAssetRegistry(
    bytes32 salt,
    address owner_,
    address vault,
    IAssetRegistry.AssetInformation[] memory assets,
    IERC20 numeraireToken,
    IERC20 feeToken,
    AggregatorV2V3Interface sequencer
) external override onlyOwnerOrV2Factory returns (address deployed);

Parameters

Returns

deployHooks

Deploy hooks.

function deployHooks(
    bytes32 salt,
    address owner_,
    address vault,
    uint256 minDailyValue,
    TargetSighashData[] memory targetSighashAllowlist
) external override onlyOwnerOrV2Factory returns (address deployed);

Parameters

Returns

Events

AssetRegistryCreated

EVENTS ///

Emitted when the asset registry is created.

event AssetRegistryCreated(
    address indexed assetRegistry,
    address indexed vault,
    address indexed owner,
    IAssetRegistry.AssetInformation[] assets,
    IERC20 numeraireToken,
    IERC20 feeToken,
    IERC20 wrappedNativeToken,
    AggregatorV2V3Interface sequencer
);

HooksCreated

Emitted when the hooks is created.

event HooksCreated(
    address indexed hooks,
    address indexed vault,
    address indexed owner,
    uint256 minDailyValue,
    TargetSighashData[] targetSighashAllowlist
);

Errors

Aera_CallerIsNeitherOwnerOrV2Factory

MODIFIERS ///

error Aera_CallerIsNeitherOwnerOrV2Factory();

Aera__V2FactoryIsZeroAddress

error Aera__V2FactoryIsZeroAddress();

Last updated