class TwigThemeTestController

Controller routines for Twig theme test routes.

Hierarchy

Expanded class hierarchy of TwigThemeTestController

File

drupal/core/modules/system/tests/modules/twig_theme_test/lib/Drupal/twig_theme_test/TwigThemeTestController.php, line 16
Contains \Drupal\twig_theme_test\TwigThemeTestController.

Namespace

Drupal\twig_theme_test
View source
class TwigThemeTestController implements ControllerInterface {

  /**
   * Creates the controller.
   */
  public static function create(ContainerInterface $container) {
    return new static();
  }

  /**
   * Menu callback for testing PHP variables in a Twig template.
   */
  public function phpVariablesRender() {
    return theme('twig_theme_test_php_variables');
  }

}

Members

Namesort descending Modifiers Type Description Overrides
TwigThemeTestController::create public static function Creates the controller. Overrides ControllerInterface::create
TwigThemeTestController::phpVariablesRender public function Menu callback for testing PHP variables in a Twig template.