function FieldItemBase::__get
Same name in other branches
- 8.9.x core/lib/Drupal/Core/Field/FieldItemBase.php \Drupal\Core\Field\FieldItemBase::__get()
- 10 core/lib/Drupal/Core/Field/FieldItemBase.php \Drupal\Core\Field\FieldItemBase::__get()
- 11.x core/lib/Drupal/Core/Field/FieldItemBase.php \Drupal\Core\Field\FieldItemBase::__get()
Overrides FieldItemInterface::__get
1 call to FieldItemBase::__get()
- LayoutSectionItem::__get in core/
modules/ layout_builder/ src/ Plugin/ Field/ FieldType/ LayoutSectionItem.php - Magic method: Gets a property value.
2 methods override FieldItemBase::__get()
- LayoutSectionItem::__get in core/
modules/ layout_builder/ src/ Plugin/ Field/ FieldType/ LayoutSectionItem.php - Magic method: Gets a property value.
- MapItem::__get in core/
lib/ Drupal/ Core/ Field/ Plugin/ Field/ FieldType/ MapItem.php - Magic method: Gets a property value.
File
-
core/
lib/ Drupal/ Core/ Field/ FieldItemBase.php, line 136
Class
- FieldItemBase
- An entity field item.
Namespace
Drupal\Core\FieldCode
public function __get($name) {
// There is either a property object or a plain value - possibly for a
// not-defined property. If we have a plain value, directly return it.
if (isset($this->properties[$name])) {
return $this->properties[$name]
->getValue();
}
elseif (isset($this->values[$name])) {
return $this->values[$name];
}
}
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.