Browse Source

sort the FCFS list

Sven Czarnian 3 năm trước cách đây
mục cha
commit
c835944e8d
1 tập tin đã thay đổi với 1 bổ sung0 xóa
  1. 1 0
      aman/sys/RecedingHorizonControl.py

+ 1 - 0
aman/sys/RecedingHorizonControl.py

@@ -109,6 +109,7 @@ class RecedingHorizonControl:
 
         # check if we found relevant inbounds
         if 0 != len(inbounds):
+            inbounds.sort(key = lambda x: x.InitialArrivalTime)
             return inbounds, earliestArrivalTime
         else:
             return None, None