• Модуль: catalog
  • Путь к файлу: ~/bitrix/modules/catalog/lib/v2/BaseIblockElementRepository.php
  • Класс: BitrixCatalogv2BaseIblockElementRepository
  • Вызов: BaseIblockElementRepository::getEntityById
public function getEntityById(int $id): ?BaseIblockElementEntity
{
	if ($id <= 0)
	{
		throw new OutOfRangeException($id);
	}

	$entities = $this->getEntitiesBy([
		'filter' => [
			'=ID' => $id,
		],
	]);

	return reset($entities) ?: null;
}