Refactoring ITask class.