Skip to main content

MockPCVDepositV2

Functions

constructor

function constructor(
address _core,
address _token,
uint256 _resistantBalance,
uint256 _resistantProtocolOwnedFei
) public

Parameters

NameTypeDescription
_coreaddress
_tokenaddress
_resistantBalanceuint256
_resistantProtocolOwnedFeiuint256

receive

function receive() external

set

function set(
uint256 _resistantBalance,
uint256 _resistantProtocolOwnedFei
) public

Parameters

NameTypeDescription
_resistantBalanceuint256
_resistantProtocolOwnedFeiuint256

resistantBalanceAndFei

function resistantBalanceAndFei() external returns (uint256, uint256)

gets the resistant token balance and protocol owned fei of this deposit

deposit

function deposit() external

withdraw

function withdraw(
address to,
uint256 amount
) external

Parameters

NameTypeDescription
toaddress
amountuint256

withdrawERC20

function withdrawERC20(
address token,
address to,
uint256 amount
) external

Parameters

NameTypeDescription
tokenaddress
toaddress
amountuint256

withdrawETH

function withdrawETH(
address payable to,
uint256 amount
) external

Parameters

NameTypeDescription
toaddress payable
amountuint256

balance

function balance() external returns (uint256)

gets the effective balance of "balanceReportedIn" token if the deposit were fully withdrawn