method
public
static
UserTypePropertyElist::convertValueSingle()
Сигнатура
public static convertValueSingle(FieldType $fieldType, mixed $value, string $toTypeClass) : bool|int|float|string
Параметры
$fieldType
FieldType
Тип поля документа.
$value
mixed
Значение поля.
$toTypeClass
string
Имя класса типа.
Возвращаемое значение
bool|int|float|string
Как применяется в UserTypePropertyElist
UserTypePropertyElist::convertValueSingle() — метод класса \Bitrix\Iblock\BizprocType\UserTypePropertyElist модуля «Информационные блоки».
Статический метод — вызывается через имя класса UserTypePropertyElist, без создания объекта.
use Bitrix\Main\Loader;
use Bitrix\Iblock\BizprocType\UserTypePropertyElist;
Loader::includeModule('iblock');
$fieldType = null; // FieldType
$value = null;
$toTypeClass = '';
$result = UserTypePropertyElist::convertValueSingle($fieldType, $value, $toTypeClass);
// $result: bool|int|float|stringДругие методы UserTypePropertyElist
addError()addErrors()addFormat()canRenderControl()clearValueMultiple()clearValueSingle()compareValues()convertFrom()convertPropertyToView()convertTo()convertValueMultiple()externalizeValue()
convertValueSingle() есть и у других классов модуля «Информационные блоки»: UserTypeProperty, UserTypePropertyDiskFile, UserTypePropertyEmployee, UserTypePropertyHtml.
Исходный файл: source/iblock/lib/bizproctype/usertypepropertyelist.php:189

