public function finished()
    {
        if ($this->tasksCount == 0) {
            if (isset($this->callback)) {
                $results = array();
                foreach ($this->tasks as $task) {
                    $results[] = $task->result;
                }

                call_user_func($this->callback, $results);
            }

            return true;
        }

        return false;
    }