public function Mapper::updateInfo in Feeds Paragraphs 8
Updates a property of TargetInfo object.
Parameters
FieldDefinitionInterface $field:
$property:
$value:
Return value
bool true on success.
2 calls to Mapper::updateInfo()
- Mapper::getSubFields in src/
Mapper.php - Mapper::getTargets in src/
Mapper.php
File
- src/
Mapper.php, line 219
Class
Namespace
Drupal\feeds_para_mapperCode
public function updateInfo(FieldDefinitionInterface $field, $property, $value) {
$info = $field
->get('target_info');
if (!isset($info)) {
$info = new TargetInfo();
}
$res = false;
if (property_exists(TargetInfo::class, $property)) {
$info->{$property} = $value;
$field
->set('target_info', $info);
$res = true;
}
return $res;
}