Factory
#
Functions#
constructorsets the owner of the factory responsible for creating pools
#
createPoolgiven an address of an ERC-20 token, creates a pool and initializes it. This is gas optimized to use the CREATE2 op code when creating a pool.
#
Parameters:Name | Type | Description |
---|---|---|
token | address | the ERC-20 token to create the pool for |
#
poolsreturns the total number of pools created
#
poolgiven an address, returns the address of the underlying pool
#
Parameters:Name | Type | Description |
---|---|---|
token | address | the address of the underlying ERC-20 token |
#
setOwnersets the owner of the factory
#
Parameters:Name | Type | Description |
---|---|---|
o | address | the new owner |
#
ownerreturns the current owner of the factory