method
public
static
PlainText::readFromStorage()
Сигнатура
public static readFromStorage(Storage $storage, mixed $from) : static|false
Параметры
$storage
Storage
$from
mixed
Возвращаемое значение
static|false
Как применяется в PlainText
PlainText::readFromStorage() — метод класса \Bitrix\DocumentGenerator\Body\PlainText модуля «Генератор документов».
Статический метод — вызывается через имя класса PlainText, без создания объекта.
use Bitrix\Main\Loader;
use Bitrix\DocumentGenerator\Body\PlainText;
Loader::includeModule('documentgenerator');
$storage = null; // Storage
$from = null;
$result = PlainText::readFromStorage($storage, $from);
// $result: static|falseДругие методы PlainText
detectHtml()getCodeFromPlaceholder()getContent()getFieldNames()getFields()getFileExtension()getFileMimeType()getPlaceholders()getStorage()isFileProcessable()normalizeContent()Нормализует содержимое body.process()Разобрать $content, обработать команды, заполнить значения.
readFromStorage() есть и у других классов модуля «Генератор документов»: Body, Docx, DocxXml, Xml, ZipDocument.
Исходный файл: source/documentgenerator/lib/body/plaintext.php:50

