function EntityContentBase::getIds
Same name in other branches
- 9 core/modules/migrate/src/Plugin/migrate/destination/EntityContentBase.php \Drupal\migrate\Plugin\migrate\destination\EntityContentBase::getIds()
- 8.9.x core/modules/migrate/src/Plugin/migrate/destination/EntityContentBase.php \Drupal\migrate\Plugin\migrate\destination\EntityContentBase::getIds()
- 11.x core/modules/migrate/src/Plugin/migrate/destination/EntityContentBase.php \Drupal\migrate\Plugin\migrate\destination\EntityContentBase::getIds()
Overrides MigrateDestinationInterface::getIds
2 methods override EntityContentBase::getIds()
- EntityContentComplete::getIds in core/
modules/ migrate/ src/ Plugin/ migrate/ destination/ EntityContentComplete.php - EntityRevision::getIds in core/
modules/ migrate/ src/ Plugin/ migrate/ destination/ EntityRevision.php
File
-
core/
modules/ migrate/ src/ Plugin/ migrate/ destination/ EntityContentBase.php, line 251
Class
- EntityContentBase
- Provides destination class for all content entities lacking a specific class.
Namespace
Drupal\migrate\Plugin\migrate\destinationCode
public function getIds() {
$ids = [];
$id_key = $this->getKey('id');
$ids[$id_key] = $this->getDefinitionFromEntity($id_key);
if ($this->isTranslationDestination()) {
$langcode_key = $this->getKey('langcode');
if (!$langcode_key) {
throw new MigrateException(sprintf('The "%s" entity type does not support translations.', $this->storage
->getEntityTypeId()));
}
$ids[$langcode_key] = $this->getDefinitionFromEntity($langcode_key);
}
return $ids;
}
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.