Update ScheduleWriter.cpp

this workaround of iterating over enums compiles