You are here

WebformEntityViewBuilder.php in Webform 8.5

Same filename and directory in other branches
  1. 6.x src/WebformEntityViewBuilder.php

Namespace

Drupal\webform

File

src/WebformEntityViewBuilder.php
View source
<?php

namespace Drupal\webform;

use Drupal\Core\Entity\EntityInterface;
use Drupal\Core\Entity\EntityViewBuilder;

/**
 * Render controller for webform.
 */
class WebformEntityViewBuilder extends EntityViewBuilder {

  /**
   * {@inheritdoc}
   */
  public function view(EntityInterface $entity, $view_mode = 'full', $langcode = NULL) {

    /* @var $entity \Drupal\webform\WebformInterface */
    return $entity
      ->getSubmissionForm();
  }

}

Classes

Namesort descending Description
WebformEntityViewBuilder Render controller for webform.