Skip to main content

PCVDripController

Functions

constructor

function constructor(
address _core,
contract IPCVDeposit _source,
contract IPCVDeposit _target,
uint256 _frequency,
uint256 _dripAmount,
uint256 _incentiveAmount
) public

PCV Drip Controller constructor

Parameters

NameTypeDescription
_coreaddressFei Core for reference
_sourcecontract IPCVDepositthe PCV deposit to drip from
_targetcontract IPCVDepositthe PCV deposit to drip to
_frequencyuint256frequency of dripping
_dripAmountuint256amount to drip on each drip
_incentiveAmountuint256the FEI incentive for calling drip

drip

function drip() external

drip PCV to target by withdrawing from source

setSource

function setSource(
contract IPCVDeposit newSource
) external

set the new PCV Deposit source

Parameters

NameTypeDescription
newSourcecontract IPCVDeposit

setTarget

function setTarget(
contract IPCVDeposit newTarget
) external

set the new PCV Deposit target

Parameters

NameTypeDescription
newTargetcontract IPCVDeposit

setDripAmount

function setDripAmount(
uint256 newDripAmount
) external

set the new drip amount

Parameters

NameTypeDescription
newDripAmountuint256

dripEligible

function dripEligible() public returns (bool)

checks whether the target balance is less than the drip amount

_mintFei

function _mintFei(
address to,
uint256 amountIn
) internal

Parameters

NameTypeDescription
toaddress
amountInuint256