Skip to content

Commit

Permalink
Modifications to scheduler & abstract schedule class. ready to test
Browse files Browse the repository at this point in the history
  • Loading branch information
antara-chugh committed Jul 31, 2024
1 parent 13ca202 commit 7ddb266
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 163 deletions.
8 changes: 5 additions & 3 deletions src/a_scheduler.cpp
Original file line number Diff line number Diff line change
@@ -1,10 +1,11 @@
#include "a_scheduler.hpp"


Scheduler:: Scheduler(DeploymentSchedule_t schedule[], int length): AbstractScheduler(schedule){
Scheduler:: Scheduler(DeploymentSchedule_t schedule[]){
tasks=schedule;
numTasks=length;
for(int i=0; i<numTasks; i++){

int i=0;
for(; tasks[i].measure; i++){
if(i=0){
tasks[i].startDelay=0;
}else {
Expand All @@ -14,6 +15,7 @@ Scheduler:: Scheduler(DeploymentSchedule_t schedule[], int length): AbstractSche
}

}
int numTasks=i-1;

}

Expand Down
2 changes: 1 addition & 1 deletion src/a_scheduler.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ class Scheduler : public AbstractScheduler{
DeploymentSchedule_t * tasks;
int numTasks;
public:
Scheduler(DeploymentSchedule_t schedule[], int length);
Scheduler(DeploymentSchedule_t schedule[]);
int getNextTask(const DeploymentSchedule_t* p_next_task,
std::uint32_t* p_next_runtime,
std::uint32_t current_time);
Expand Down
4 changes: 1 addition & 3 deletions src/abstractScheduler.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@

class AbstractScheduler {
public:
AbstractScheduler(DeploymentSchedule_t schedule[]);

/**
* Creates and initializes the schedule
*/
Expand All @@ -33,7 +33,5 @@ class AbstractScheduler {
std::uint32_t* p_next_runtime,
std::uint32_t current_time) = 0;
};
inline AbstractScheduler::AbstractScheduler(DeploymentSchedule_t *schedule){

}
#endif // __ABSTRACT_SCHEDULER_HPP__
156 changes: 0 additions & 156 deletions src/scheduler.hpp

This file was deleted.

0 comments on commit 7ddb266

Please sign in to comment.