Table of Contents

Method WhenAnyNewOrderBookAsync

Namespace
WhalesSecret.TradeScriptLib.API.TradingV1.MarketData
Assembly
WhalesSecret.TradeScriptLib.dll

WhenAnyNewOrderBookAsync()

Waits for a new order book on any subscription in the set.

Task<OrderBook> WhenAnyNewOrderBookAsync()

Returns

Task<OrderBook>

Up-to-date order book.

Exceptions

OperationCanceledException

Thrown if the operation was cancelled, including cancellation during the shutdown.

InvalidStateException

Thrown if:

  • the method is called while another class method that may change the internal state of any subscription in the set is in progress, or
  • the method is called without calling StartBatchMonitoring(CancellationToken) first.
NotFoundException

Thrown if the method is called and while it is waiting, a subscription is removed from the set and disposed.