function EntityTypeManager::hasHandler

Same name and namespace in other branches
  1. 9 core/lib/Drupal/Core/Entity/EntityTypeManager.php \Drupal\Core\Entity\EntityTypeManager::hasHandler()
  2. 10 core/lib/Drupal/Core/Entity/EntityTypeManager.php \Drupal\Core\Entity\EntityTypeManager::hasHandler()
  3. 11.x core/lib/Drupal/Core/Entity/EntityTypeManager.php \Drupal\Core\Entity\EntityTypeManager::hasHandler()

Overrides EntityTypeManagerInterface::hasHandler

File

core/lib/Drupal/Core/Entity/EntityTypeManager.php, line 196

Class

EntityTypeManager
Manages entity type plugin definitions.

Namespace

Drupal\Core\Entity

Code

public function hasHandler($entity_type_id, $handler_type) {
    if ($definition = $this->getDefinition($entity_type_id, FALSE)) {
        return $definition->hasHandlerClass($handler_type);
    }
    return FALSE;
}

Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.