function FieldAPIHandlerTrait::getEntityFieldManager

Same name in other branches
  1. 9 core/modules/views/src/FieldAPIHandlerTrait.php \Drupal\views\FieldAPIHandlerTrait::getEntityFieldManager()
  2. 8.9.x core/modules/views/src/FieldAPIHandlerTrait.php \Drupal\views\FieldAPIHandlerTrait::getEntityFieldManager()
  3. 11.x core/modules/views/src/FieldAPIHandlerTrait.php \Drupal\views\FieldAPIHandlerTrait::getEntityFieldManager()

Returns the entity field manager.

Return value

\Drupal\Core\Entity\EntityFieldManagerInterface The entity field manager.

File

core/modules/views/src/FieldAPIHandlerTrait.php, line 74

Class

FieldAPIHandlerTrait
A trait containing helper methods for field definitions.

Namespace

Drupal\views

Code

protected function getEntityFieldManager() {
    if (!isset($this->entityFieldManager)) {
        $this->entityFieldManager = \Drupal::service('entity_field.manager');
    }
    return $this->entityFieldManager;
}

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