private void ClearOrderChanged()
 {
     if (enableSyncTicks && tickSync.SentOrderChange)
     {
         tickSync.RemoveOrderChange();
     }
 }
Exemple #2
0
 private void TryCompleteTick()
 {
     if (endOfTickData)
     {
         if (tickSync.SentSwtichBrokerState)
         {
             tickSync.ClearSwitchBrokerState("Finished.");
         }
         if (tickSync.SentOrderChange)
         {
             tickSync.RemoveOrderChange();
         }
     }
     if (!endOfTickData && tickSync.Completed)
     {
         if (verbose)
         {
             log.Verbose("TryCompleteTick() Next Tick");
         }
         tickSync.Clear();
     }
     else if (tickSync.OnlyProcessPhysicalOrders)
     {
         if (trace)
         {
             log.Trace("Process physical orders - " + tickSync);
         }
         FillSimulator.StartTick(nextTick);
         if (FillSimulator.IsChanged)
         {
             FillSimulator.ProcessOrders();
         }
         tickSync.RemoveProcessPhysicalOrders();
     }
     else if (tickSync.OnlyReprocessPhysicalOrders || FillSimulator.IsChanged)
     {
         if (trace)
         {
             log.Trace("Reprocess physical orders - " + tickSync);
         }
         if (FillSimulator.IsChanged)
         {
             FillSimulator.ProcessOrders();
         }
         if (tickSync.SentReprocessPhysicalOrders)
         {
             tickSync.ClearReprocessPhysicalOrders();
         }
     }
 }