/** * @param Ekino\Bundle\DrupalBundle\Drupal\DrupalInterface $drupal */ public function buildResponse(DrupalInterface $drupal) { if ($drupal->isFound()) { $drupal->buildContent(); } $drupal->render(); }
/** * Render drupal. */ protected function drupalRender() { if ($this->drupal->isFound()) { $this->drupal->buildContent(); } $this->drupal->render(); }
/** * @param GetResponseEvent $event * * @return mixed */ public function onKernelRequest(GetResponseEvent $event) { if (HttpKernelInterface::MASTER_REQUEST !== $event->getRequestType()) { return false; } $this->drupal->defineState($event->getRequest()); $this->strategy->buildResponse($this->drupal); $response = $this->drupal->getResponse(); if ($this->drupal->hasResponse()) { $event->setResponse($response); } }
/** * @param DrupalInterface $drupal */ public function buildResponse(DrupalInterface $drupal) { if ($drupal->is404()) { $drupal->disableResponse(); return; } if ($drupal->isFound()) { $drupal->buildContent(); } $drupal->render(); }
/** * @param DrupalInterface $drupal */ public function buildResponse(DrupalInterface $drupal) { $drupal->disableResponse(); }
/** * Gets the entity controller * * @param string $entityType An entity type * * @return \DrupalDefaultEntityController */ public function getController($entityType) { return $this->drupal->getEntityController($entityType); }