Package com.xeiam.xchange

Examples of com.xeiam.xchange.ExchangeException


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

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


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

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

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

    // String tradableIdentifier, BigDecimal last, BigDecimal bid, BigDecimal ask, BigDecimal high, BigDecimal low, BigDecimal volume, Date timestamp
    // base & counter currencies hard coded in; no way to make it dynamic with return data - may change over time.
    BigDecimal last = rawRetObj.getLast();
View Full Code Here

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

    synchronized (cachedDataSynchronizationObject) {
      // base & counter currencies hard coded in; no way to make it dynamic with return data - may change over time.
View Full Code Here

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

    synchronized (cachedDataSynchronizationObject) {
View Full Code Here

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

    synchronized (cachedDataSynchronizationObject) {
      List<LimitOrder> bidList = (cachedOrderBook == null ? new ArrayList<LimitOrder>() : cachedOrderBook.getBids());
      List<LimitOrder> askList = (cachedOrderBook == null ? new ArrayList<LimitOrder>() : cachedOrderBook.getAsks());
View Full Code Here

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

    synchronized (cachedDataSynchronizationObject) {
      List<LimitOrder> bidList = (cachedOrderBook == null ? new ArrayList<LimitOrder>() : cachedOrderBook.getBids());
      List<LimitOrder> askList = (cachedOrderBook == null ? new ArrayList<LimitOrder>() : cachedOrderBook.getAsks());
View Full Code Here

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

    Trade trade;

    synchronized (cachedDataSynchronizationObject) {
View Full Code Here

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

    List<Wallet> newWallets = new ArrayList<Wallet>();
    AccountInfo accountInfo;
View Full Code Here

   */
  public AccountInfo getCachedAccountInfo() {

    synchronized (cachedDataSynchronizationObject) {
      if (cachedAccountInfo == null) {
        throw new ExchangeException("getBalances method has not been called yet, or balance data has not been recieved!");
      }
      return cachedAccountInfo;
    }
  }
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.