Package com.xeiam.xchange.bittrex.v1.dto.trade

Examples of com.xeiam.xchange.bittrex.v1.dto.trade.BittrexCancelOrderResponse


    super(BittrexAuthenticated.class, exchangeSpecification);
  }

  public List<BittrexBalance> getBittrexAccountInfo() throws IOException {

    BittrexBalancesResponse response = bittrex.balances(apiKey, signatureCreator, String.valueOf(nextNonce()));

    if (response.getSuccess()) {
      return response.getResult();
    }
    else {
      throw new ExchangeException(response.getMessage());
    }
  }
View Full Code Here


    }
  }

  public String getBittrexDepositAddress(String currency) throws IOException {

    BittrexDepositAddressResponse response = bittrex.getdepositaddress(apiKey, signatureCreator, String.valueOf(nextNonce()), currency);
    if (response.getSuccess()) {
      return response.getResult().getAddress();
    }
    else {
      throw new ExchangeException(response.getMessage());
    }
  }
View Full Code Here

    super(Bittrex.class, exchangeSpecification);
  }

  public BittrexCurrency[] getBittrexCurrencies() throws IOException {

    BittrexCurrenciesResponse response = bittrex.getCurrencies();

    if (response.isSuccess()) {
      return response.getCurrencies();
    }
    else {
      throw new ExchangeException(response.getMessage());
    }

  }
View Full Code Here

    BittrexDepthResponse response = bittrex.getBook(pair, "both", depth);

    if (response.getSuccess()) {

      BittrexDepth bittrexDepth = response.getDepth();
      return bittrexDepth;
    }
    else {
      throw new ExchangeException(response.getMessage());
    }
View Full Code Here

      if (args[0] instanceof Integer && (Integer) args[0] > 0 && (Integer) args[0] <= 50) {
        depth = (Integer) args[0];
      }
    }

    BittrexDepth bittrexDepth = getBittrexOrderBook(BittrexUtils.toPairString(currencyPair), depth);

    List<LimitOrder> asks = BittrexAdapters.adaptOrders(bittrexDepth.getAsks(), currencyPair, "ask", "");
    List<LimitOrder> bids = BittrexAdapters.adaptOrders(bittrexDepth.getBids(), currencyPair, "bid", "");

    return new OrderBook(null, asks, bids);
  }
View Full Code Here

    System.out.println(ticker);

    ArrayList<BittrexTicker> tickers = marketDataService.getBittrexTickers();
    System.out.println(tickers);

    BittrexDepth orderBook = marketDataService.getBittrexOrderBook(pairString, 50);
    System.out.println(orderBook);

    BittrexTrade[] trades = marketDataService.getBittrexTrades(pairString, 100);
    System.out.println(Arrays.asList(trades));
  }
View Full Code Here

  }

  public BittrexDepth getBittrexOrderBook(String pair, int depth) throws IOException {

    BittrexDepthResponse response = bittrex.getBook(pair, "both", depth);

    if (response.getSuccess()) {

      BittrexDepth bittrexDepth = response.getDepth();
      return bittrexDepth;
    }
    else {
      throw new ExchangeException(response.getMessage());
    }
  }
View Full Code Here

  }

  public ArrayList<BittrexSymbol> getBittrexSymbols() throws IOException {

    BittrexSymbolsResponse response = bittrex.getSymbols();

    if (response.isSuccess()) {
      return response.getSymbols();
    }
    else {
      throw new ExchangeException(response.getMessage());
    }

  }
View Full Code Here

    CurrencyPair pair = pairs.get(new Random().nextInt(pairs.size()));
    System.out.println("Market data for " + pair + ":");
    String pairString = BittrexUtils.toPairString(pair);

    BittrexTicker ticker = marketDataService.getBittrexTicker(pairString);
    System.out.println(ticker);

    ArrayList<BittrexTicker> tickers = marketDataService.getBittrexTickers();
    System.out.println(tickers);
View Full Code Here

  }

  public BittrexTicker getBittrexTicker(String pair) throws IOException {

    BittrexTickerResponse response = bittrex.getTicker(pair);

    if (response.getSuccess()) {
      return response.getTicker();
    }
    else {
      throw new ExchangeException(response.getMessage());
    }

  }
View Full Code Here

TOP

Related Classes of com.xeiam.xchange.bittrex.v1.dto.trade.BittrexCancelOrderResponse

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.