You are here

protected function EntityHandlerBase::isEntityTypeTranslatable in CMS Content Sync 8

Same name and namespace in other branches
  1. 2.1.x src/Plugin/EntityHandlerBase.php \Drupal\cms_content_sync\Plugin\EntityHandlerBase::isEntityTypeTranslatable()
  2. 2.0.x src/Plugin/EntityHandlerBase.php \Drupal\cms_content_sync\Plugin\EntityHandlerBase::isEntityTypeTranslatable()

Parameters

\Drupal\Core\Entity\EntityInterface $entity:

Return value

bool

2 calls to EntityHandlerBase::isEntityTypeTranslatable()
EntityHandlerBase::push in src/Plugin/EntityHandlerBase.php
EntityHandlerBase::setEntityValues in src/Plugin/EntityHandlerBase.php
Set the values for the pulled entity.

File

src/Plugin/EntityHandlerBase.php, line 789

Class

EntityHandlerBase
Common base class for entity handler plugins.

Namespace

Drupal\cms_content_sync\Plugin

Code

protected function isEntityTypeTranslatable($entity) {
  return $entity instanceof TranslatableInterface && $entity
    ->getEntityType()
    ->getKey('langcode');
}