Beispiel #1
0
        public void UnsubscribeSymbols()
        {
            SymbolsRequest sr = new SymbolsRequest
            {
                Channel = ChannelType.Symbols,
                Action  = ActionType.Unsubscribe
            };

            AddMessageToQueue(sr);
        }
Beispiel #2
0
        public Task <List <string> > GetSupportedSymbolsAsync()
        {
            if (!IsConnected)
            {
                throw new Exception("Client is not connected!");
            }

            // Create a new async context
            var context = new GetSupportedSymbolsAsyncContext();

            // Create a new QH cache request
            var request = new SymbolsRequest(0)
            {
                RequestId = Guid.NewGuid().ToString()
            };

            // Send request to the server
            _session.SendSymbolsRequest(context, request);

            // Return result task
            return(context.Tcs.Task);
        }