use of org.knowm.xchange.latoken.dto.account.LatokenBalance in project XChange by knowm.
the class LatokenAccountService method getAccountInfo.
@Override
public AccountInfo getAccountInfo() throws IOException {
try {
List<LatokenBalance> latokenBalances = getLatokenBalances();
List<Balance> balances = latokenBalances.stream().map(latokenBalance -> LatokenAdapters.adaptBalance(latokenBalance)).collect(Collectors.toList());
Wallet wallet = Wallet.Builder.from(balances).build();
return new AccountInfo(null, TRADING_FEE, Arrays.asList(wallet), new Date());
} catch (LatokenException e) {
throw LatokenErrorAdapter.adapt(e);
}
}
Aggregations