You are here

public function Flow::getEntityTypeHandler in CMS Content Sync 2.0.x

Same name and namespace in other branches
  1. 8 src/Entity/Flow.php \Drupal\cms_content_sync\Entity\Flow::getEntityTypeHandler()

The the entity type handler for the given config.

Parameters

$config: {@see Flow::getEntityTypeConfig()}

Return value

\Drupal\cms_content_sync\Plugin\EntityHandlerInterface

File

src/Entity/Flow.php, line 947

Class

Flow
Defines the "Content Sync - Flow" entity.

Namespace

Drupal\cms_content_sync\Entity

Code

public function getEntityTypeHandler($config) {
  $entityPluginManager = \Drupal::service('plugin.manager.cms_content_sync_entity_handler');
  return $entityPluginManager
    ->createInstance($config['handler'], [
    'entity_type_name' => $config['entity_type_name'],
    'bundle_name' => $config['bundle_name'],
    'settings' => $config,
    'sync' => $this,
  ]);
}