This event is emitted when funds are migrated to the new exchange, specified by the address 'newExchange'.
event FundsMigrated(address indexed user, address indexed newExchange);
parameter | type |
---|---|
user | address |
newExchange | address |
With this function the owner can set the address of the new version of the exchange contract.
function setNewExchangeAddress(address exchange) external onlyOwner
parameter | type |
---|---|
exchange | address |
This function is used to enable or disable the migrations. Can be called only by the owner.
function allowOrRestrictMigrations() external onlyOwner
This function is used to migrate assets of the caller to the new exchange contract.
function migrateFunds(address[] calldata tokens) external
parameter | type |
---|---|
tokens | array of addresses |
This is a helper function used to migrate users' Ethers. It should be called only from the new exchange contract.
function importEthers(address user) external payable
parameter | type |
---|---|
user | address |
This is a helper function used to migrate users' Tokens. It should be called only from the new exchange contract.
function importTokens(address token, uint256 amount,
address user) external
parameter | type |
---|---|
token | address |
amount | uint256 |
user | address |