摘要 |
A task scheduler executes a number of tasks. Each task is assigned a folder. Different methods of executing a task are assigned sub-folders of the task folder. A list of the sub folders is generated. The names of the folders may indicate the priorities of the methods. The list may be ordered according to those priorities. The names of the folders may also indicate parameters for the tasks. When the scheduler executes a task, it finds the next sub-folder in the list and moves it to an active task folder. It then executes the corresponding method. When a task method completes successfully, the sub-folder is moved to a sub-folder of successful tasks and all the sub-folders for the task are removed from the list. When a task completes unsuccessfully, the sub-folder is moved to a sub-folder of unsuccessful tasks and the sub-folder is removed from the list. |