• Модуль: im
  • Путь к файлу: ~/bitrix/modules/im/lib/V2/Controller/BaseController.php
  • Класс: BitrixImV2ControllerBaseController
  • Вызов: BaseController::getAutoWiredParameters
public function getAutoWiredParameters()
{
	return [
		new ExactParameter(
			Chat::class,
			'chat',
			function($className, string $dialogId) {
				$chatId = Dialog::getChatId($dialogId);

				return Chat::getInstance((int)$chatId);
			}
		),
		new ExactParameter(
			Chat::class,
			'chat',
			function($className, int $chatId) {
				return Chat::getInstance($chatId);
			}
		),
		new ExactParameter(
			Message::class,
			'message',
			function ($className, int $messageId) {
				return $this->getMessageById($messageId);
			}
		),
	];
}