Supports tasks with different types