protected function EntityDisplayBase::getFieldDefinitions in Zircon Profile 8.0
Same name and namespace in other branches
- 8 core/lib/Drupal/Core/Entity/EntityDisplayBase.php \Drupal\Core\Entity\EntityDisplayBase::getFieldDefinitions()
Gets the definitions of the fields that are candidate for display.
3 calls to EntityDisplayBase::getFieldDefinitions()
- EntityDisplayBase::getFieldDefinition in core/
lib/ Drupal/ Core/ Entity/ EntityDisplayBase.php - Gets the field definition of a field.
- EntityDisplayBase::init in core/
lib/ Drupal/ Core/ Entity/ EntityDisplayBase.php - Initializes the display.
- EntityDisplayBase::toArray in core/
lib/ Drupal/ Core/ Entity/ EntityDisplayBase.php - Gets an array of all property values.
File
- core/
lib/ Drupal/ Core/ Entity/ EntityDisplayBase.php, line 390 - Contains \Drupal\Core\Entity\EntityDisplayBase.
Class
- EntityDisplayBase
- Provides a common base class for entity view and form displays.
Namespace
Drupal\Core\EntityCode
protected function getFieldDefinitions() {
if (!isset($this->fieldDefinitions)) {
$definitions = \Drupal::entityManager()
->getFieldDefinitions($this->targetEntityType, $this->bundle);
// For "official" view modes and form modes, ignore fields whose
// definition states they should not be displayed.
if ($this->mode !== static::CUSTOM_MODE) {
$definitions = array_filter($definitions, array(
$this,
'fieldHasDisplayOptions',
));
}
$this->fieldDefinitions = $definitions;
}
return $this->fieldDefinitions;
}