protected function EntityReferenceHandlerBase::loadReferencedEntity in CMS Content Sync 2.1.x
Same name and namespace in other branches
- 8 src/Plugin/EntityReferenceHandlerBase.php \Drupal\cms_content_sync\Plugin\EntityReferenceHandlerBase::loadReferencedEntity()
- 2.0.x src/Plugin/EntityReferenceHandlerBase.php \Drupal\cms_content_sync\Plugin\EntityReferenceHandlerBase::loadReferencedEntity()
Load the entity that is either referenced or embedded by $definition.
Parameters
$definition:
Return value
\Drupal\Core\Entity\EntityInterface
Throws
\Drupal\Component\Plugin\Exception\PluginNotFoundException
\Drupal\Core\Entity\EntityStorageException
\Drupal\cms_content_sync\Exception\SyncException
\Drupal\Component\Plugin\Exception\InvalidPluginDefinitionException
2 calls to EntityReferenceHandlerBase::loadReferencedEntity()
- DefaultFieldCollectionHandler::loadReferencedEntity in src/
Plugin/ cms_content_sync/ field_handler/ DefaultFieldCollectionHandler.php - Load the entity that is either referenced or embedded by $definition.
- EntityReferenceHandlerBase::setValues in src/
Plugin/ EntityReferenceHandlerBase.php
2 methods override EntityReferenceHandlerBase::loadReferencedEntity()
- DefaultFieldCollectionHandler::loadReferencedEntity in src/
Plugin/ cms_content_sync/ field_handler/ DefaultFieldCollectionHandler.php - Load the entity that is either referenced or embedded by $definition.
- DefaultUserReferenceHandler::loadReferencedEntity in src/
Plugin/ cms_content_sync/ field_handler/ DefaultUserReferenceHandler.php - Load the entity that is either referenced or embedded by $definition.
File
- src/
Plugin/ EntityReferenceHandlerBase.php, line 365
Class
- EntityReferenceHandlerBase
- Providing a base implementation for any reference field type.
Namespace
Drupal\cms_content_sync\PluginCode
protected function loadReferencedEntity(PullIntent $intent, $definition) {
return $intent
->loadEmbeddedEntity($definition);
}