function ContentEntityStorageBase::isAnyRevisionTranslated
Same name in other branches
- 9 core/lib/Drupal/Core/Entity/ContentEntityStorageBase.php \Drupal\Core\Entity\ContentEntityStorageBase::isAnyRevisionTranslated()
- 8.9.x core/lib/Drupal/Core/Entity/ContentEntityStorageBase.php \Drupal\Core\Entity\ContentEntityStorageBase::isAnyRevisionTranslated()
- 10 core/lib/Drupal/Core/Entity/ContentEntityStorageBase.php \Drupal\Core\Entity\ContentEntityStorageBase::isAnyRevisionTranslated()
Checks whether any entity revision is translated.
Parameters
\Drupal\Core\Entity\TranslatableInterface $entity: The entity object to be checked.
Return value
bool TRUE if the entity has at least one translation in any revision, FALSE otherwise.
See also
\Drupal\Core\TypedData\TranslatableInterface::getTranslationLanguages()
\Drupal\Core\Entity\ContentEntityStorageBase::isAnyStoredRevisionTranslated()
1 call to ContentEntityStorageBase::isAnyRevisionTranslated()
- ContentEntityStorageBase::createRevision in core/
lib/ Drupal/ Core/ Entity/ ContentEntityStorageBase.php - Creates a new revision starting off from the specified entity object.
File
-
core/
lib/ Drupal/ Core/ Entity/ ContentEntityStorageBase.php, line 299
Class
- ContentEntityStorageBase
- Base class for content entity storage handlers.
Namespace
Drupal\Core\EntityCode
protected function isAnyRevisionTranslated(TranslatableInterface $entity) {
return $entity->getTranslationLanguages(FALSE) || $this->isAnyStoredRevisionTranslated($entity);
}
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.