/// <summary> /// Create a new order book instance /// </summary> /// <param name="symbol">The symbol the order book is for</param> /// <param name="limit">The number of entries in the order book</param> /// <param name="options">Options for the order book</param> public BittrexSymbolOrderBook(string symbol, int limit, BittrexOrderBookOptions?options = null) : base(symbol, options ?? new BittrexOrderBookOptions()) { symbol.ValidateBittrexSymbol(); limit.ValidateIntValues(nameof(limit), 1, 25, 500); _limit = limit; socketClient = options?.SocketClient ?? new BittrexSocketClient(new BittrexSocketClientOptions() { LogVerbosity = options?.LogVerbosity ?? LogVerbosity.Info }); client = new BittrexClient(new BittrexClientOptions() { LogVerbosity = options?.LogVerbosity ?? LogVerbosity.Info }); }
/// <summary> /// Create a new order book instance /// </summary> /// <param name="symbol">The symbol the order book is for</param> /// <param name="options">Options for the order book</param> public BittrexSymbolOrderBook(string symbol, BittrexOrderBookOptions options = null) : base(symbol, options ?? new BittrexOrderBookOptions()) { socketClient = options?.SocketClient ?? new BittrexSocketClient(); }
/// <summary> /// </summary> /// <param name="socketClient">The client to use for the socket connection. When using the same client for multiple order books the connection can be shared.</param> public BittrexOrderBookOptions(IBittrexSocketClient socketClient = null) : base("Bittrex", true) { SocketClient = socketClient; }