Refactored Scheduler Class