<?php
/**
 * @copyright (c) Kufer Software GmbH, Oderstraße 7, D-84453 Mühldorf
 */

namespace Kufer\Web\KuferTools\Dozent\Lehrplan\Lehrplan;

class LehrplanController extends \Kufer\Web\KuferTools\Basis\Uebersicht\UebersichtController
{
  protected function getUseCase(): \Kufer\Web\KuferTools\Basis\UseCase\UseCase
  {
    return new LehrplanUseCase(
      $this->getRequestObj()
    );
  }

  protected function getToolId()
  {
    return LehrplanUseCase::getToolId();
  }

  protected function getDefaultRequestObj()
  {
    $request = new LehrplanRequest();
    $request->filter_datum_von = \GetOperations::getVarValue('datVon');
    $request->filter_datum_bis = \GetOperations::getVarValue('datBis');

    return $request;
  }

  protected function getSuchAPI()
  {
    return new \LehrplanSucheAPI();
  }

  protected function getRequestSearchName()
  {
    return 'searchkurs';
  }

  protected function getPresenter($pUseCaseResponse)
  {
    return new LehrplanPresenter($pUseCaseResponse);
  }
}