Implemented nextTask() and added an abstract method to
SchedulingAlgorithm.