Refactor schedule class and extract course data into JSON file.