/
IProvider.sol
28 lines (17 loc) · 940 Bytes
/
IProvider.sol
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
// SPDX-License-Identifier: Apache-2.0
pragma solidity ^0.7.6;
pragma abicoder v2;
interface IProvider {
function smartYield() external view returns (address);
function controller() external view returns (address);
function underlyingFees() external view returns (uint256);
// deposit underlyingAmount_ into provider, add takeFees_ to fees
function _depositProvider(uint256 underlyingAmount_, uint256 takeFees_) external;
// withdraw underlyingAmount_ from provider, add takeFees_ to fees
function _withdrawProvider(uint256 underlyingAmount_, uint256 takeFees_) external;
function _takeUnderlying(address from_, uint256 amount_) external;
function _sendUnderlying(address to_, uint256 amount_) external returns (bool);
function transferFees() external;
// current total underlying balance as measured by the provider pool
function underlyingBalance() external returns (uint256);
}