}
@Override
public void onError(SocketIOException socketIOException) {
putEvent(new DefaultExchangeEvent(ExchangeEventType.ERROR, socketIOException.getMessage(), socketIOException));
}
});
super.addListener(new CoinsetterExchangeAdapter() {
@Override
public void onTicker(CoinsetterTicker coinsetterTicker) {
Ticker ticker = CoinsetterAdapters.adaptTicker(coinsetterTicker);
putEvent(new DefaultExchangeEvent(ExchangeEventType.TICKER, null, ticker));
}
@Override
public void onDepth(CoinsetterPair[] depth) {
OrderBook orderBook = CoinsetterAdapters.adaptOrderBook(depth);
putEvent(new DefaultExchangeEvent(ExchangeEventType.DEPTH, null, orderBook));
}
});
}