/// <summary>
 /// Konstruktor wczytujacy ciagi procesow z zadanej sciezki do zmiennej LoadedProcesses,
 /// przechowywane w odpowiednim formacie XML
 /// Inicjalizuje obiekt ProcesUtilities i ustawia cyclesNumber na 0, kwant czas ustawiony na 10
 /// </summary>
 /// <param name="processUtilities">Obiekt klasy ProcessUtilities</param>
 public RoundRobinLCFS(ProcessUtilities processUtilities, double quantum)
 {
     LoadedProcesses       = new List <List <Process> >(processUtilities.LoadManyListOfProcessesFromSerializedXMLs());
     this.processUtilities = processUtilities;
     cyclesNumber          = 0;
     this.quantum          = quantum;
     foreach (List <Process> list in LoadedProcesses)
     {
         foreach (Process process in list)
         {
             process.WaitingTime -= process.CpuBurstTime;
         }
     }
 }
예제 #2
0
 /// <summary>
 /// Konstruktor wczytujacy ciagi procesow z zadanej sciezki, przechowywane w odpowiednim formacie XML
 /// Inicjalizuje obiekt ProcesUtilities i ustawia cyclesNumber na 0
 /// </summary>
 /// <param name="processUtilities">Obiekt klasy ProcessUtilities</param>
 public SJF(ProcessUtilities processUtilities)
 {
     LoadedProcesses       = new List <List <Process> >(processUtilities.LoadManyListOfProcessesFromSerializedXMLs());
     this.processUtilities = processUtilities;
     cyclesNumber          = 0;
 }