public function EntityRenderController::view

Implements \Drupal\Core\Entity\EntityRenderControllerInterface::view().

Overrides EntityRenderControllerInterface::view

1 call to EntityRenderController::view()
1 method overrides EntityRenderController::view()

File

drupal/core/lib/Drupal/Core/Entity/EntityRenderController.php, line 89
Contains \Drupal\Core\Entity\EntityRenderController.

Class

EntityRenderController
Base class for entity view controllers.

Namespace

Drupal\Core\Entity

Code

public function view(EntityInterface $entity, $view_mode = 'full', $langcode = NULL) {
  $buildList = $this
    ->viewMultiple(array(
    $entity,
  ), $view_mode, $langcode);
  return $buildList[0];
}