• Модуль: tasks
  • Путь к файлу: ~/bitrix/modules/tasks/lib/processor/task/scheduler.php
  • Класс: BitrixTasksProcessorTaskScheduler
  • Вызов: Scheduler::getRelationProcessor
public function getRelationProcessor($code)
{
	if (!($this->processors[$code] ?? null))
	{
		$instance = null;
		if($code == 'S')
		{
			$instance = new SubTask();
		}
		elseif($code == 'P')
		{
			$instance = new Project();
		}
		else
		{
			throw new NotImplementedException();
		}

		$instance->setScheduler($this);
		$this->processors[$code] = $instance;
	}

	return $this->processors[$code];
}