CollateralAuctionHouseChild
Inherits: DisableableChild, AuthorizableChild, CollateralAuctionHouse, ICollateralAuctionHouseChild
This contract inherits all the functionality of CollateralAuctionHouse to be factory deployed
Functions
constructor
constructor(
address _safeEngine,
address _liquidationEngine,
address _oracleRelayer,
bytes32 _cType,
CollateralAuctionHouseParams memory _cahParams
) CollateralAuctionHouse(_safeEngine, _liquidationEngine, _oracleRelayer, _cType, _cahParams);
Parameters
Name | Type | Description |
---|---|---|
_safeEngine | address | Address of the SAFEEngine contract |
_liquidationEngine | address | Ignored parameter (read from factory) |
_oracleRelayer | address | Ignored parameter (read from factory) |
_cType | bytes32 | Bytes32 representation of the collateral type |
_cahParams | CollateralAuctionHouseParams | Initial valid CollateralAuctionHouse parameters struct |
liquidationEngine
Address of the LiquidationEngine contract
Overriding method reads liquidationEngine from factory
function liquidationEngine()
public
view
override(CollateralAuctionHouse, ICollateralAuctionHouse)
returns (ILiquidationEngine _liquidationEngine);
oracleRelayer
Address of the OracleRelayer contract
Overriding method reads oracleRelayer from factory
function oracleRelayer()
public
view
override(CollateralAuctionHouse, ICollateralAuctionHouse)
returns (IOracleRelayer _oracleRelayer);
_setLiquidationEngine
Modifying liquidationEngine's address results in a no-operation (is read from factory)
function _setLiquidationEngine(address _newLiquidationEngine) internal override;
Parameters
Name | Type | Description |
---|---|---|
_newLiquidationEngine | address | Ignored parameter (read from factory) |
_setOracleRelayer
Modifying oracleRelayer's address results in a no-operation (is read from factory)
function _setOracleRelayer(address _newOracleRelayer) internal override;
Parameters
Name | Type | Description |
---|---|---|
_newOracleRelayer | address | Ignored parameter (read from factory) |
_isAuthorized
Method override to check for authorization also in the parent factory
function _isAuthorized(address _account)
internal
view
override(AuthorizableChild, Authorizable)
returns (bool _authorized);
Parameters
Name | Type | Description |
---|---|---|
_account | address | Account to check authorization for |
Returns
Name | Type | Description |
---|---|---|
_authorized | bool | Whether the account is authorized either in contract or in factory |
_isEnabled
Method override to check for contract enablement also in the parent factory
function _isEnabled() internal view override(DisableableChild, Disableable) returns (bool _enabled);
Returns
Name | Type | Description |
---|---|---|
_enabled | bool | Whether the contract and the factory are enabled or not |
_onContractDisable
Method override to allow disabling contract only through the parent factory
function _onContractDisable() internal override(DisableableChild, Disableable);