HaiProxyRegistry
Inherits: IHaiProxyRegistry
This contract is used to deploy and keep track of the user's proxy instances
The registry deploys new proxies using HaiProxyFactory contract
State Variables
proxies
Mapping of user addresses to proxy instances
mapping(address _owner => IHaiProxy) public proxies;
factory
Address of the proxy factory
IHaiProxyFactory public factory;
Functions
constructor
constructor(address _factory);
Parameters
Name | Type | Description |
---|---|---|
_factory | address | Address of the HaiProxyFactory contract |
build
Deploys a new proxy instance, setting the caller as the owner
function build() public returns (address payable _proxy);
Returns
Name | Type | Description |
---|---|---|
_proxy | address payable | Address of the new proxy |
build
Deploys a new proxy instance, setting the caller as the owner
function build(address _owner) public returns (address payable _proxy);
Returns
Name | Type | Description |
---|---|---|
_proxy | address payable | Address of the new proxy |
_build
Internal method used to deploy a new proxy instance and store it in the registry
function _build(address _owner) internal returns (address payable _proxy);