added enum TaskState