IProtocolReader.sol
1 pragma solidity >=0.6.0; 2 pragma experimental ABIEncoderV2; 3 4 import "../interfaces/IProposalWrapper.sol"; 5 6 interface IProtocolReader { 7 struct poolData { 8 string[] poolSymbols; 9 address[] poolAddrs; 10 uint[] poolApy; 11 uint[] poolBalance; 12 uint[] poolFreeBalance; 13 uint[] userPoolBalance; 14 uint[] userPoolUsdValue; 15 uint[] poolMaturityDate; 16 uint[] poolWithdrawalFee; 17 string[] poolSymbolList; 18 } 19 struct proposalData { 20 address[] addr; 21 address[] wrapperAddr; 22 address[] govToken; 23 IProposalWrapper.VoteType[] voteType; 24 IProposalWrapper.Status[] status; 25 bool[] isActive; 26 27 } 28 struct poolOptions { 29 string[] poolSymbols; 30 address[] poolAddrs; 31 string[] poolOptionsRaw; 32 } 33 struct poolPricesData { 34 //address[] poolAddrs; 35 uint[] poolBuyPrice; 36 uint[] poolSellPrice; 37 uint[] poolBuyPriceVolume; 38 uint[] poolSellPriceVolume; 39 } 40 function listPoolsData(address account) external view returns (poolData memory); 41 function listProposals() external view returns (proposalData memory); 42 function listPoolOptions() external view returns (poolOptions memory); 43 function listPoolsPrices(string calldata optionSymbol, address[] calldata poolAddressList) external view returns (poolPricesData memory); 44 }