IExchanger¶
Description¶
Source: contracts/interfaces/IExchanger.sol
Structs¶
ExchangeEntry
¶
Field | Type | Description |
---|---|---|
sourceRate |
uint256 |
TBA |
destinationRate |
uint256 |
TBA |
destinationAmount |
uint256 |
TBA |
exchangeFeeRate |
uint256 |
TBA |
exchangeDynamicFeeRate |
uint256 |
TBA |
roundIdForSrc |
uint256 |
TBA |
roundIdForDest |
uint256 |
TBA |
sourceAmountAfterSettlement |
uint256 |
TBA |
ExchangeEntrySettlement
¶
Field | Type | Description |
---|---|---|
src |
bytes32 |
TBA |
amount |
uint256 |
TBA |
dest |
bytes32 |
TBA |
reclaim |
uint256 |
TBA |
rebate |
uint256 |
TBA |
srcRoundIdAtPeriodEnd |
uint256 |
TBA |
destRoundIdAtPeriodEnd |
uint256 |
TBA |
timestamp |
uint256 |
TBA |
Views¶
calculateAmountAfterSettlement
¶
Details
Signature
calculateAmountAfterSettlement(address from, bytes32 currencyKey, uint256 amount, uint256 refunded) view returns (uint256 amountAfterSettlement)
Visibility
external
State Mutability
view
dynamicFeeRateForExchange
¶
Details
Signature
dynamicFeeRateForExchange(bytes32 sourceCurrencyKey, bytes32 destinationCurrencyKey) view returns (uint256 feeRate, bool tooVolatile)
Visibility
external
State Mutability
view
feeRateForExchange
¶
Details
Signature
feeRateForExchange(bytes32 sourceCurrencyKey, bytes32 destinationCurrencyKey) view returns (uint256)
Visibility
external
State Mutability
view
getAmountsForExchange
¶
Details
Signature
getAmountsForExchange(uint256 sourceAmount, bytes32 sourceCurrencyKey, bytes32 destinationCurrencyKey) view returns (uint256 amountReceived, uint256 fee, uint256 exchangeFeeRate)
Visibility
external
State Mutability
view
hasWaitingPeriodOrSettlementOwing
¶
Details
Signature
hasWaitingPeriodOrSettlementOwing(address account, bytes32 currencyKey) view returns (bool)
Visibility
external
State Mutability
view
isSynthRateInvalid
¶
Details
Signature
isSynthRateInvalid(bytes32 currencyKey) view returns (bool)
Visibility
external
State Mutability
view
lastExchangeRate
¶
Details
Signature
lastExchangeRate(bytes32 currencyKey) view returns (uint256)
Visibility
external
State Mutability
view
maxSecsLeftInWaitingPeriod
¶
Details
Signature
maxSecsLeftInWaitingPeriod(address account, bytes32 currencyKey) view returns (uint256)
Visibility
external
State Mutability
view
priceDeviationThresholdFactor
¶
Details
Signature
priceDeviationThresholdFactor() view returns (uint256)
Visibility
external
State Mutability
view
settlementOwing
¶
Details
Signature
settlementOwing(address account, bytes32 currencyKey) view returns (uint256 reclaimAmount, uint256 rebateAmount, uint256 numEntries)
Visibility
external
State Mutability
view
waitingPeriodSecs
¶
Details
Signature
waitingPeriodSecs() view returns (uint256)
Visibility
external
State Mutability
view
External Functions¶
exchange
¶
Details
Signature
exchange(address exchangeForAddress, address from, bytes32 sourceCurrencyKey, uint256 sourceAmount, bytes32 destinationCurrencyKey, address destinationAddress, bool virtualSynth, address rewardAddress, bytes32 trackingCode) returns (uint256 amountReceived, contract IVirtualSynth vSynth)
Visibility
external
State Mutability
``
exchangeAtomically
¶
Details
Signature
exchangeAtomically(address from, bytes32 sourceCurrencyKey, uint256 sourceAmount, bytes32 destinationCurrencyKey, address destinationAddress, bytes32 trackingCode, uint256 minAmount) returns (uint256 amountReceived)
Visibility
external
State Mutability
``
settle
¶
Details
Signature
settle(address from, bytes32 currencyKey) returns (uint256 reclaimed, uint256 refunded, uint256 numEntries)
Visibility
external
State Mutability
``