public function EntityAdapter::onChange in Zircon Profile 8.0
Same name and namespace in other branches
- 8 core/lib/Drupal/Core/Entity/Plugin/DataType/EntityAdapter.php \Drupal\Core\Entity\Plugin\DataType\EntityAdapter::onChange()
React to changes to a child property or item.
Note that this is invoked after any changes have been applied.
Parameters
$name: The name of the property or the delta of the list item which is changed.
Overrides TraversableTypedDataInterface::onChange
File
- core/
lib/ Drupal/ Core/ Entity/ Plugin/ DataType/ EntityAdapter.php, line 146 - Contains \Drupal\Core\Entity\Plugin\DataType\EntityAdapter.
Class
- EntityAdapter
- Defines the "entity" data type.
Namespace
Drupal\Core\Entity\Plugin\DataTypeCode
public function onChange($property_name) {
if (isset($this->entity) && $this->entity instanceof FieldableEntityInterface) {
// Let the entity know of any changes.
$this->entity
->onChange($property_name);
}
}