USDCCurrency

This contract is a specific implementation of the BaseCurrency for USDC.

Since USDC is already in USDC value, this simply returns the given amount

constructor

constructor(address _erc20) public

Constructor sets the address for the ERC20 token.

Parameters

Name
Type
Description

_erc20

address

The address of the ERC20 token to be used as the base currency.

getEstimatedUSDCValue

function getEstimatedUSDCValue(uint256 _amount) public view virtual returns (uint256)

Returns the estimated value in USDC of an amount of the base currency.

For USDC, the return value is the same as the input value (_amount).

Parameters

Name
Type
Description

_amount

uint256

The amount of base currency to estimate the value of.

Return Values

Name
Type
Description

[0]

uint256

The estimated value in USDC of the specified amount of base currency.

Last updated