Esempio n. 1
0
		/// <summary>
		/// Initializes a new instance of the <see cref="ScannerMarketDataMessage"/>.
		/// </summary>
		/// <param name="filter">Filter.</param>
		public ScannerMarketDataMessage(ScannerFilter filter)
		{
			if (filter == null)
				throw new ArgumentNullException("filter");

			Filter = filter;
			DataType = ExtendedMarketDataTypes.Scanner;
		}
Esempio n. 2
0
        /// <summary>
        /// Initializes a new instance of the <see cref="ScannerMarketDataMessage"/>.
        /// </summary>
        /// <param name="filter">Filter.</param>
        public ScannerMarketDataMessage(ScannerFilter filter)
        {
            if (filter == null)
            {
                throw new ArgumentNullException(nameof(filter));
            }

            Filter   = filter;
            DataType = ExtendedMarketDataTypes.Scanner;
        }
Esempio n. 3
0
        /// <summary>
        /// To start or stop the instruments scanner based on specified parameters. The results will come through the <see cref="IBTrader.NewScannerResults"/> event.
        /// </summary>
        /// <param name="filter">Filter.</param>
        /// <param name="isSubscribe"><see langword="true" /> if you need to subscribe, otherwise <see langword="false" />.</param>
        public void SubscribeScanner(ScannerFilter filter, bool isSubscribe)
        {
            var transactionId = TransactionIdGenerator.GetNextId();

            _states.Add(transactionId, filter);

            SendInMessage(new ScannerMarketDataMessage(filter)
            {
                TransactionId = transactionId,
                IsSubscribe   = isSubscribe
            });
        }
Esempio n. 4
0
		/// <summary>
		/// To start or stop the instruments scanner based on specified parameters. The results will come through the <see cref="IBTrader.NewScannerResults"/> event.
		/// </summary>
		/// <param name="filter">Filter.</param>
		/// <param name="isSubscribe"><see langword="true" /> if you need to subscribe, otherwise <see langword="false" />.</param>
		public void SubscribeScanner(ScannerFilter filter, bool isSubscribe)
		{
			var transactionId = TransactionIdGenerator.GetNextId();

			_states.Add(transactionId, filter);

			SendInMessage(new ScannerMarketDataMessage(filter)
			{
				TransactionId = transactionId,
				IsSubscribe = isSubscribe
			});
		}