method public final

Controller::getCurrentUser()

Класс: \Bitrix\Main\Engine\Controller

Сигнатура

public final getCurrentUser() : CurrentUser

Возвращаемое значение

CurrentUser

Как применяется в Controller

Controller::getCurrentUser() — метод класса \Bitrix\Main\Engine\Controller модуля «Главный модуль».

Метод объекта: сначала нужен экземпляр Controller.

use Bitrix\Main\Engine\Controller;

/** @var Controller $object */
$result = $object->getCurrentUser();
// $result: CurrentUser

Другие методы Controller

getCurrentUser() есть и у других классов модуля «Главный модуль»: Action, ClosureAction, ComponentController, DefaultController, FallbackAction, InlineAction, InlineAction, JsonController.

Исходный файл: source/main/lib/engine/controller.php:268

Что будем искать? Например,Продвижение