ICollateralAuctionHouseFactory
Inherits: IAuthorizable, IModifiable
Functions
cParams
Getter for the collateral parameters struct
function cParams(bytes32 _cType)
external
view
returns (ICollateralAuctionHouse.CollateralAuctionHouseParams memory _cahParams);
Parameters
Name | Type | Description |
---|---|---|
_cType | bytes32 | Bytes32 representation of the collateral type |
Returns
Name | Type | Description |
---|---|---|
_cahParams | ICollateralAuctionHouse.CollateralAuctionHouseParams | CollateralAuctionHouse parameters struct |
_cParams
Getter for the unpacked collateral parameters struct
function _cParams(bytes32 _cType)
external
view
returns (uint256 _minimumBid, uint256 _minDiscount, uint256 _maxDiscount, uint256 _perSecondDiscountUpdateRate);
Parameters
Name | Type | Description |
---|---|---|
_cType | bytes32 | Bytes32 representation of the collateral type |
Returns
Name | Type | Description |
---|---|---|
_minimumBid | uint256 | Minimum bid for the collateral auctions [wad] |
_minDiscount | uint256 | Minimum discount for the collateral auctions [wad %] |
_maxDiscount | uint256 | Maximum discount for the collateral auctions [wad %] |
_perSecondDiscountUpdateRate | uint256 | Per second rate at which the discount is updated [ray] |
safeEngine
Address of the SAFEEngine contract
function safeEngine() external view returns (address _safeEngine);
liquidationEngine
Address of the LiquidationEngine contract
function liquidationEngine() external view returns (address _liquidationEngine);
oracleRelayer
Address of the OracleRelayer contract
function oracleRelayer() external view returns (address _oracleRelayer);
collateralAuctionHouses
Getter for the address of the CollateralAuctionHouse contract associated with a collateral type
function collateralAuctionHouses(bytes32 _cType) external view returns (address _collateralAuctionHouse);
Parameters
Name | Type | Description |
---|---|---|
_cType | bytes32 | Bytes32 representation of the collateral type |
Returns
Name | Type | Description |
---|---|---|
_collateralAuctionHouse | address | Address of the CollateralAuctionHouse contract |
collateralList
Getter for the list of collateral types
function collateralList() external view returns (bytes32[] memory __collateralList);
Returns
Name | Type | Description |
---|---|---|
__collateralList | bytes32[] | List of collateral types |
collateralAuctionHousesList
Getter for the list of CollateralAuctionHouse contracts
function collateralAuctionHousesList() external view returns (address[] memory _collateralAuctionHouses);
Returns
Name | Type | Description |
---|---|---|
_collateralAuctionHouses | address[] | List of CollateralAuctionHouse contracts |
deployCollateralAuctionHouse
Deploys a CollateralAuctionHouse contract
function deployCollateralAuctionHouse(
bytes32 _cType,
ICollateralAuctionHouse.CollateralAuctionHouseParams calldata _cahParams
) external returns (ICollateralAuctionHouse _collateralAuctionHouse);
Parameters
Name | Type | Description |
---|---|---|
_cType | bytes32 | Bytes32 representation of the collateral type |
_cahParams | ICollateralAuctionHouse.CollateralAuctionHouseParams | Initial valid CollateralAuctionHouse parameters |
Returns
Name | Type | Description |
---|---|---|
_collateralAuctionHouse | ICollateralAuctionHouse | Address of the deployed CollateralAuctionHouse contract |
Events
DeployCollateralAuctionHouse
Emitted when a new CollateralAuctionHouse contract is deployed
event DeployCollateralAuctionHouse(bytes32 indexed _cType, address indexed _collateralAuctionHouse);
Errors
CAHFactory_CAHExists
Throws when trying to deploy a CollateralAuctionHouse contract for an existent collateral type
error CAHFactory_CAHExists();