#include <event.h>
|
| Event (double time, bool renew=true) |
| Event constructor. More...
|
|
void | setTask (std::shared_ptr< Process > task) |
| if the event is specific to a task, set it here. TODO not all events have an associated task. This should be moved More...
|
|
double | getTime () |
| get the time at which the event is scheduled More...
|
|
virtual void | process ()=0 |
| handle the the event TODO: 'process' is maybe not the best word for that, given that our simulator actually manipulated processes More...
|
|
virtual | ~Event () |
|
virtual void | print () |
| print information about the event More...
|
|
virtual std::string | getName ()=0 |
| get the name of the event More...
|
|
Definition at line 26 of file event.h.
Event::Event |
( |
double |
time, |
|
|
bool |
renew = true |
|
) |
| |
Event constructor.
- Parameters
-
time | the time at which the event is to be scheduled |
renew | set this to true if the event has to be repeated (for periodic events). It will then reschedule itself according to its behavior. |
Definition at line 23 of file event.cpp.
virtual std::string Scheduler::Event::getName |
( |
| ) |
|
|
pure virtual |
get the name of the event
- Returns
- a string containing the name of the event
Implemented in Scheduler::DummyEvent, Scheduler::FreqUpdate, Scheduler::StatsTick, Scheduler::UsageUpdate, Scheduler::SchedTimeOut, Scheduler::NewJob, Scheduler::NewInteractiveProcess, Scheduler::NewProcess, Scheduler::StartProc, Scheduler::Terminates, Scheduler::MissedDeadline, Scheduler::Ready, Scheduler::StopSimulation, and Scheduler::Waiting.
double Event::getTime |
( |
| ) |
|
get the time at which the event is scheduled
- Returns
- the time at which the event is scheduled
Definition at line 36 of file event.cpp.
virtual void Scheduler::Event::process |
( |
| ) |
|
|
pure virtual |
handle the the event TODO: 'process' is maybe not the best word for that, given that our simulator actually manipulated processes
Implemented in Scheduler::NewJob, Scheduler::NewInteractiveProcess, Scheduler::NewProcess, Scheduler::StartProc, Scheduler::Terminates, Scheduler::MissedDeadline, Scheduler::Ready, Scheduler::StopSimulation, Scheduler::Waiting, and Scheduler::TimeOut.
void Event::setTask |
( |
std::shared_ptr< Process > |
task | ) |
|
if the event is specific to a task, set it here. TODO not all events have an associated task. This should be moved
Definition at line 31 of file event.cpp.
The event type is need by the scheduling discipline, to determine if this kind of event triggers invokatio of that discipline.
Definition at line 64 of file event.h.
bool Scheduler::Event::renew |
|
protected |
std::shared_ptr<Process> Scheduler::Event::task {nullptr} |
|
protected |
double Scheduler::Event::time |
|
protected |
The documentation for this class was generated from the following files: