Exemple #1
0
 public WebSocketSubscribeInfo(SocketSubscribeType type, Ticker ticker)
 {
     Type    = type;
     Ticker  = ticker;
     Command = new WebSocketCommandInfo();
     if (Ticker != null)
     {
         channel = Ticker.Name;
     }
 }
Exemple #2
0
 public SocketConnectionInfo(Exchange exchange, Ticker ticker, string address, SocketType socketType, SocketSubscribeType connType)
 {
     if (connType == SocketSubscribeType.OrderBook ||
         connType == SocketSubscribeType.TradeHistory ||
         connType == SocketSubscribeType.Kline)
     {
         if (ticker == null)
         {
             throw new Exception("Ticker should not be null");
         }
     }
     Ticker     = ticker;
     Exchange   = exchange;
     Name       = ticker == null ? Exchange.Name : ticker.Name;
     Type       = connType;
     SocketType = socketType;
     Address    = address;
 }
Exemple #3
0
 public SocketConnectionInfo(string name, SocketSubscribeType type)
 {
     Name = name;
     Type = type;
 }