2020-05-29 16:45:37 +00:00
|
|
|
// SPDX-License-Identifier: agpl-3.0
|
|
|
|
pragma solidity ^0.6.8;
|
|
|
|
|
2020-10-15 13:41:56 +00:00
|
|
|
import {IERC20} from '../dependencies/openzeppelin/contracts/IERC20.sol';
|
2020-05-29 16:45:37 +00:00
|
|
|
|
|
|
|
interface IExchangeAdapter {
|
2020-07-13 08:54:08 +00:00
|
|
|
event Exchange(
|
|
|
|
address indexed from,
|
|
|
|
address indexed to,
|
|
|
|
address indexed platform,
|
|
|
|
uint256 fromAmount,
|
|
|
|
uint256 toAmount
|
|
|
|
);
|
2020-05-29 16:45:37 +00:00
|
|
|
|
2020-08-21 13:38:47 +00:00
|
|
|
function approveExchange(IERC20[] calldata tokens) external;
|
2020-05-29 16:45:37 +00:00
|
|
|
|
2020-07-13 08:54:08 +00:00
|
|
|
function exchange(
|
2020-08-21 13:38:47 +00:00
|
|
|
address from,
|
|
|
|
address to,
|
|
|
|
uint256 amount,
|
|
|
|
uint256 maxSlippage
|
2020-07-13 08:54:08 +00:00
|
|
|
) external returns (uint256);
|
2020-06-02 14:16:22 +00:00
|
|
|
}
|