use of org.knowm.xchange.lakebtc.dto.trade.LakeBTCCancelResponse in project XChange by knowm.
the class LakeBTCCancelOrderDemo method raw.
private static void raw(Exchange lakeBtcExchange) throws IOException {
LakeBTCTradeServiceRaw tradeService = (LakeBTCTradeServiceRaw) lakeBtcExchange.getTradeService();
System.out.println("Open Orders: " + Arrays.toString(tradeService.getLakeBTCOrders()));
// place a limit buy order
LimitOrder limitOrder = new LimitOrder((Order.OrderType.ASK), new BigDecimal(".01"), CurrencyPair.BTC_LTC, "", null, new BigDecimal("51.25"));
LakeBTCOrderResponse limitOrderReturnValue = tradeService.placeLakeBTCLimitOrder(limitOrder);
System.out.println("Limit Order return value: " + limitOrderReturnValue);
// Cancel the added order
LakeBTCCancelResponse cancelResult = tradeService.cancelLakeBTCOrder(limitOrderReturnValue.getId());
System.out.println("Canceling returned " + cancelResult.getResult());
}
Aggregations