Метод isAutoGeneratedTitle

private static

Сигнатура метода

private static function isAutoGeneratedTitle(mixed $title, string $activityType): bool

Возвращает: bool

Описание

The title the builder writes for a node the source left without one: '###<lang prefix><TYPE>_TITLE###', where the prefix is the name of the agent in upper case (TemplateBuilder::getActivityTitle()). The name itself is unknown here - the comparator reads the two templates and asks nothing else - so what the check allows in its place is the shape of a lang prefix, and nothing wider: a name is written in lowercase letters, digits and underscores (TPL-06), the build upper-cases it. A title the original does state is never called generated, however much it reads like one - that is why compareNode() asks this about the rebuilt node alone. The reverse carries such a title into the source verbatim, so the build has to write it back unchanged; excusing it by its shape would let a title written by hand fall out of the report, and the agent would ship with the title of the build instead.

Параметры

2
Имя Тип По умолчанию Флаги
$title mixed —
—
$activityType string —
—

Расположение

Исходный файл метода в Bitrix Framework

Путь к исходному файлу Source
~/bitrix/modulesbizproc/lib/Internal/AI/Agent/Generator/TemplateReverser/TemplateComparator.php
Расположение метода в файле
Строки 995–1006

Исходный код

PHP