#include <scheduler.hpp>
|
| FCFS () |
| A First Come First Serve (FCFS) scheduler.
|
|
| ~FCFS () |
|
std::vector< std::unique_ptr< Process > > | schedule (time_unit ¤tTime, std::shared_ptr< Logger > logger, time_unit quantum=-1) |
| This function represents moving forward by a single unit in time.
|
|
bool | addToReadyQueue (std::unique_ptr< Process > &process, time_unit _currentTime=-1) |
| This function represents the addition of a newly arrived process to the ready queue.
|
|
◆ FCFS()
A First Come First Serve (FCFS) scheduler.
◆ ~FCFS()
◆ addToReadyQueue()
bool FCFS::addToReadyQueue |
( |
std::unique_ptr< Process > & |
process, |
|
|
time_unit |
currentTime = -1 |
|
) |
| |
|
virtual |
This function represents the addition of a newly arrived process to the ready queue.
- Parameters
-
process | The process to add |
currentTime | The simulation time when the process arrived, i.e., now |
Implements Scheduler.
◆ schedule()
This function represents moving forward by a single unit in time.
- Parameters
-
currentTime | The current simulation time |
logger | The Logger instance to use for event logging |
quantum | The time quantum (if required by the scheduler) |
- Returns
- std::vector<std::unique_ptr<Process>> The list of scheduled processes till now
Implements Scheduler.
The documentation for this class was generated from the following files: