Package com.xeiam.xchange

Examples of com.xeiam.xchange.ExchangeException


    try {
      ANXDepthWrapper anxDepthWrapper = anxV2.getFullDepth(currencyPair.baseSymbol, currencyPair.counterSymbol);
      return anxDepthWrapper;
    } catch (ANXException e) {
      throw new ExchangeException("Error calling getANXFullOrderBook(): " + e.getError(), e);
    }
  }
View Full Code Here


        return book;
      }
      ANXDepthsWrapper anxDepthWrapper = anxV2.getFullDepths(pathCurrencyPair.baseSymbol, pathCurrencyPair.counterSymbol, extraCurrencyPairs.toString());
      return anxDepthWrapper.getAnxDepths();
    } catch (ANXException e) {
      throw new ExchangeException("Error calling getANXFullOrderBook(): " + e.getError(), e);
    }
  }
View Full Code Here

    try {
      ANXDepthWrapper anxDepthWrapper = anxV2.getPartialDepth(currencyPair.baseSymbol, currencyPair.counterSymbol);
      return anxDepthWrapper;
    } catch (ANXException e) {
      throw new ExchangeException("Error calling getANXPartialOrderBook(): " + e.getError(), e);
    }
  }
View Full Code Here

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

    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

    BTCTradeSecretResponse response = btcTrade.getSecret(exchangeSpecification.getSecretKey(), exchangeSpecification.getApiKey());
    if (response.getResult()) {
      return response.getData();
    }
    else {
      throw new ExchangeException(response.getMessage());
    }
  }
View Full Code Here

    CoinfloorBalances rawRetObj;
    try {
      rawRetObj = streamObjectMapper.readValue(data, CoinfloorBalances.class);
    } catch (IOException e) {
      throw new ExchangeException("JSON parse error", e);
    }
    resultMap.put("raw", rawRetObj);

    List<Wallet> wallets = new ArrayList<Wallet>();
    List<CoinfloorAssetBalance> funds = rawRetObj.getBalances();
View Full Code Here

    CoinfloorOpenOrders rawRetObj;
    try {
      rawRetObj = streamObjectMapper.readValue(data, CoinfloorOpenOrders.class);
    } catch (IOException e) {
      throw new ExchangeException("JSON parse error", e);
    }
    resultMap.put("raw", rawRetObj);

    List<LimitOrder> openOrdersList = new ArrayList<LimitOrder>();
    List<CoinfloorOrder> orders = rawRetObj.getOrders();
View Full Code Here

    try {
      jsonData = streamObjectMapper.readValue(data, new TypeReference<Map<String, Object>>() {
      });
      rawRetObj = streamObjectMapper.readValue(data, CoinfloorPlaceOrder.class);
    } catch (IOException e) {
      throw new ExchangeException("JSON parse error", e);
    }

    resultMap.put("generic", jsonData.get("id").toString());
    resultMap.put("raw", rawRetObj);
View Full Code Here

    CoinfloorCancelOrder rawRetObj;
    try {
      rawRetObj = streamObjectMapper.readValue(data, CoinfloorCancelOrder.class);
    } catch (IOException e) {
      throw new ExchangeException("JSON parse error", e);
    }

    resultMap.put("generic", true);
    resultMap.put("raw", rawRetObj);
View Full Code Here

TOP

Related Classes of com.xeiam.xchange.ExchangeException

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.