use of com.github.jnidzwetzki.bitfinex.v2.entity.OrderBookFrequency in project bitfinex-v2-wss-api-java by jnidzwetzki.
the class QuoteManager method unsubscribeExecutedTrades.
/**
* Unsubscribe a executed trades channel
* @param currencyPair
* @param orderBookPrecision
* @param orderBookFrequency
* @param pricePoints
*/
public void unsubscribeExecutedTrades(final BitfinexExecutedTradeSymbol tradeSymbol) {
final int channel = bitfinexApiBroker.getChannelForSymbol(tradeSymbol);
if (channel == -1) {
throw new IllegalArgumentException("Unknown symbol: " + tradeSymbol);
}
final UnsubscribeChannelCommand command = new UnsubscribeChannelCommand(channel);
bitfinexApiBroker.sendCommand(command);
bitfinexApiBroker.removeChannelForSymbol(tradeSymbol);
}
use of com.github.jnidzwetzki.bitfinex.v2.entity.OrderBookFrequency in project bitfinex-v2-wss-api-java by jnidzwetzki.
the class RawOrderbookManager method subscribeOrderbook.
/**
* Subscribe a orderbook
* @param currencyPair
* @param orderBookPrecision
* @param orderBookFrequency
* @param pricePoints
*/
public void subscribeOrderbook(final RawOrderbookConfiguration orderbookConfiguration) {
final SubscribeRawOrderbookCommand subscribeOrderbookCommand = new SubscribeRawOrderbookCommand(orderbookConfiguration);
bitfinexApiBroker.sendCommand(subscribeOrderbookCommand);
}
use of com.github.jnidzwetzki.bitfinex.v2.entity.OrderBookFrequency in project bitfinex-v2-wss-api-java by jnidzwetzki.
the class OrderbookManager method unsubscribeOrderbook.
/**
* Unsubscribe a orderbook
* @param currencyPair
* @param orderBookPrecision
* @param orderBookFrequency
* @param pricePoints
*/
public void unsubscribeOrderbook(final OrderbookConfiguration orderbookConfiguration) {
final int channel = bitfinexApiBroker.getChannelForSymbol(orderbookConfiguration);
if (channel == -1) {
throw new IllegalArgumentException("Unknown symbol: " + orderbookConfiguration);
}
final UnsubscribeChannelCommand command = new UnsubscribeChannelCommand(channel);
bitfinexApiBroker.sendCommand(command);
bitfinexApiBroker.removeChannelForSymbol(orderbookConfiguration);
}
use of com.github.jnidzwetzki.bitfinex.v2.entity.OrderBookFrequency in project bitfinex-v2-wss-api-java by jnidzwetzki.
the class OrderbookManager method subscribeOrderbook.
/**
* Subscribe a orderbook
* @param currencyPair
* @param orderBookPrecision
* @param orderBookFrequency
* @param pricePoints
*/
public void subscribeOrderbook(final OrderbookConfiguration orderbookConfiguration) {
final SubscribeOrderbookCommand subscribeOrderbookCommand = new SubscribeOrderbookCommand(orderbookConfiguration);
bitfinexApiBroker.sendCommand(subscribeOrderbookCommand);
}
use of com.github.jnidzwetzki.bitfinex.v2.entity.OrderBookFrequency in project bitfinex-v2-wss-api-java by jnidzwetzki.
the class QuoteManager method subscribeExecutedTrades.
/**
* Subscribe a executed trade channel
* @param currencyPair
* @param orderBookPrecision
* @param orderBookFrequency
* @param pricePoints
*/
public void subscribeExecutedTrades(final BitfinexExecutedTradeSymbol tradeSymbol) {
final SubscribeTradesCommand subscribeOrderbookCommand = new SubscribeTradesCommand(tradeSymbol);
bitfinexApiBroker.sendCommand(subscribeOrderbookCommand);
}
Aggregations