コード例 #1
0
 protected void OnOrderCallback(object sender, OrderCallbackEventArgs value)
 {
     foreach (var item in Channels.Where(i => i.SecCode == value.SecCode))
     {
         item.OnOrderCallback(value);
     }
 }
コード例 #2
0
        public void OnOrderCallback(OrderCallbackEventArgs e)
        {
            if (Orders.ContainsKey(e.Number))
            {
                Orders[e.Number] = e;
            }
            else
            {
                Orders.Add(e.Number, e);
            }

            OrderCallback?.Invoke(this, e);
        }
コード例 #3
0
ファイル: OrderChannel.cs プロジェクト: valmac/quik-connector
        public void OnOrderCallback(OrderCallbackEventArgs e)
        {
            if (Orders.ContainsKey(e.Number))
            {
                Orders[e.Number] = e;
            }
            else
            {
                Orders.Add(e.Number, e);
            }

            OrderCallback?.Invoke(this, e);
        }
コード例 #4
0
ファイル: Trans2Quik.cs プロジェクト: valmac/quik-connector
        public static void order_status_callback_impl(
            Int32 nMode, UInt32 dwTransID, Double dNumber, string ClassCode, string SecCode,
            Double dPrice, Int32 nBalance, Double dValue, Int32 nIsSell, Int32 nStatus, Int32 nOrderDescriptor)
        {
            OrderCallbackEventArgs ocp = new OrderCallbackEventArgs
            {
                Mode            = nMode,
                TransID         = dwTransID,
                Number          = dNumber,
                ClassCode       = ClassCode,
                SecCode         = SecCode,
                Price           = dPrice,
                Balance         = nBalance,
                Value           = dValue,
                IsSell          = nIsSell,
                Status          = nStatus,
                OrderDescriptor = nOrderDescriptor
            };

            if (OrderCallback != null)
            {
                OrderCallback(null, ocp);
            }
        }
コード例 #5
0
        public static void order_status_callback_impl(
                Int32 nMode, UInt32 dwTransID, Double dNumber, string ClassCode, string SecCode,
                Double dPrice, Int32 nBalance, Double dValue, Int32 nIsSell, Int32 nStatus, Int32 nOrderDescriptor)
        {
            OrderCallbackEventArgs ocp = new OrderCallbackEventArgs
            {
                Mode = nMode,
                TransID = dwTransID,
                Number = dNumber,
                ClassCode = ClassCode,
                SecCode = SecCode,
                Price = dPrice,
                Balance = nBalance,
                Value = dValue,
                IsSell = nIsSell,
                Status = nStatus,
                OrderDescriptor = nOrderDescriptor
            };

            if (OrderCallback != null) OrderCallback(null, ocp);
        }
コード例 #6
0
 protected void OnOrderCallback(object sender, OrderCallbackEventArgs value)
 {
     foreach (var item in Channels.Where(i => i.SecCode == value.SecCode))
     {
         item.OnOrderCallback(value);
     }
 }