public void Run()
        {
            // Configure your credentials for IQConnect in user environment variable or app.config !!!
            // Check the documentation for more information.

            // Run IQConnect launcher
            IQFeedLauncher.Start();

            // Connect the LookupClient created from the constructor
            LookupClient.Connect();

            // Add 100 symbols to the concurrent queue
            foreach (var symbol in MarketData.GetSymbols().Skip(100).Take(200))
            {
                Symbols.Enqueue(symbol);
            }

            // Download data for all added symbols
            var sw = Stopwatch.StartNew();

            Start();
            sw.Stop();

            // Count the total of daily messages received
            var messagesFetched = 0;

            foreach (var dailyMessages in _dailyMessagesBySymbol)
            {
                messagesFetched += dailyMessages.Value.Count;
            }

            Console.WriteLine($"\nFetched {messagesFetched} Daily messages for {_dailyMessagesBySymbol.Count} stocks in {sw.Elapsed.TotalMilliseconds} ms.");
        }
        public async Task SetUp()
        {
            _lookupClient = LookupClientFactory.CreateNew();
            _lookupClient.Connect();
            var groupIds = await _lookupClient.Symbol.GetListedMarketsAsync("TEST"); // using ReqId as workaround for IQFeed 6.2 beta bug

            _groupId = groupIds.First(g => g.ShortName == "CME").ListedMarketId;
        }
Пример #3
0
        public void SetUp()
        {
            RestTestDataDirectory();

            IQFeedLauncher.Start();
            _lookupClient = LookupClientFactory.CreateNew();
            _lookupClient.Connect();
        }
Пример #4
0
        public void Run()
        {
            // Configure your credentials for IQConnect in user environment variable or app.config !!!
            // Check the documentation for more information.

            // Run IQConnect launcher
            IQFeedLauncher.Start();

            // Connect the LookupClient created from the constructor
            LookupClient.Connect();

            // Add 100 symbols to the concurrent queue
            foreach (var symbol in MarketData.GetSymbols().Take(100))
            {
                Symbols.Enqueue(symbol);
            }

            // Create required directories for saving files
            CreateDirectories();

            // Download data for all added symbols
            Start();
        }
Пример #5
0
 public void SetUp()
 {
     _lookupClient = LookupClientFactory.CreateNew();
     _lookupClient.Connect();
 }