public function RenderExampleController::__construct in Examples for Developers 8
Same name and namespace in other branches
- 3.x modules/render_example/src/Controller/RenderExampleController.php \Drupal\render_example\Controller\RenderExampleController::__construct()
Constructs a new BlockController instance.
Parameters
\Drupal\Core\Session\AccountInterface $current_user: The current user.
File
- render_example/
src/ Controller/ RenderExampleController.php, line 34
Class
- RenderExampleController
- Provides module description page and examples of building render arrays.
Namespace
Drupal\render_example\ControllerCode
public function __construct(AccountInterface $current_user) {
$this->currentUser = $current_user;
}