/**
  * Constructor.
  *
  * @param \YapepBase\Request\HttpRequest   $request    The request object. Must be a HttpRequest or descendant.
  * @param \YapepBase\Response\HttpResponse $response   The response object. Must be a HttpResponse or descendant.
  *
  * @throws \YapepBase\Exception\ControllerException   On error. (eg. incompatible request or response object)
  */
 public function __construct(IRequest $request, IResponse $response)
 {
     if (!$request instanceof HttpRequest) {
         throw new ControllerException('The specified request is not a HttpRequest', ControllerException::ERR_INCOMPATIBLE_REQUEST);
     }
     if (!$response instanceof HttpResponse) {
         throw new ControllerException('The specified response is not a HttpResponse', ControllerException::ERR_INCOMPATIBLE_RESPONSE);
     }
     parent::__construct($request, $response);
 }
Exemple #2
0
 public function _($string, $parameters = array(), $language = null)
 {
     return parent::_($string, $parameters, $language);
 }