Package com.xeiam.xchange.cryptotrade.dto.trade

Examples of com.xeiam.xchange.cryptotrade.dto.trade.CryptoTradeTrades


    // Read in the JSON from the example resources
    InputStream is = CryptoTradeTradeJsonTest.class.getResourceAsStream("/trade/example-trade-history-data.json");

    // Use Jackson to parse it
    ObjectMapper mapper = new ObjectMapper();
    CryptoTradeTrades tradeHistory = mapper.readValue(is, CryptoTradeTrades.class);

    UserTrades trades = CryptoTradeAdapters.adaptTrades(tradeHistory);

    assertThat(trades.getlastID()).isEqualTo(17);
    assertThat(trades.getTrades()).hasSize(2);
View Full Code Here


        if (args[0] != null && args[0] instanceof Long) {
          paramsBuilder.withStartId((Long) args[0]);
        }
      }
    }
    CryptoTradeTrades tradeHistory = super.getCryptoTradeTradeHistory(paramsBuilder.build());

    return CryptoTradeAdapters.adaptTrades(tradeHistory);
  }
View Full Code Here

    return getCryptoTradeTradeHistory(NO_QUERY_PARAMS);
  }

  public CryptoTradeTrades getCryptoTradeTradeHistory(CryptoTradeHistoryQueryParams queryParams) throws CryptoTradeException, IOException {

    CryptoTradeTrades trades =
        cryptoTradeProxy.getTradeHistory(queryParams.getStartId(), queryParams.getEndId(), queryParams.getStartDate(), queryParams.getEndDate(), queryParams.getCount(), queryParams.getOrdering(),
            queryParams.getCurrencyPair(), apiKey, signatureCreator, nextNonce());

    return handleResponse(trades);
  }
View Full Code Here

  private static void raw(CryptoTradeTradeServiceRaw tradeService) throws IOException, InterruptedException {

    CryptoTradeHistoryQueryParams params = CryptoTradeHistoryQueryParams.getQueryParamsBuilder().withCount(3).build();

    CryptoTradeTrades tradeHistory = tradeService.getCryptoTradeTradeHistory(params);
    System.out.println(tradeHistory);

    Thread.sleep(4000);

    CryptoTradeTransactions transactions = tradeService.getCryptoTradeTransactionHistory(params);
View Full Code Here

TOP

Related Classes of com.xeiam.xchange.cryptotrade.dto.trade.CryptoTradeTrades

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.