Skip to main content
Drupal API
User account menu
  • Log in

Breadcrumb

  1. Drupal Core 11.1.x
  2. BaseFieldOverride.php

function BaseFieldOverride::getBaseFieldDefinition

Gets the base field definition.

Return value

\Drupal\Core\Field\BaseFieldDefinition

1 call to BaseFieldOverride::getBaseFieldDefinition()
BaseFieldOverride::preSave in core/lib/Drupal/Core/Field/Entity/BaseFieldOverride.php

File

core/lib/Drupal/Core/Field/Entity/BaseFieldOverride.php, line 186

Class

BaseFieldOverride
Defines the base field override entity.

Namespace

Drupal\Core\Field\Entity

Code

protected function getBaseFieldDefinition() {
    if (!isset($this->baseFieldDefinition)) {
        $fields = \Drupal::service('entity_field.manager')->getBaseFieldDefinitions($this->entity_type);
        $this->baseFieldDefinition = $fields[$this->getName()];
    }
    return $this->baseFieldDefinition;
}

API Navigation

  • Drupal Core 11.1.x
  • Topics
  • Classes
  • Functions
  • Constants
  • Globals
  • Files
  • Namespaces
  • Deprecated
  • Services
RSS feed
Powered by Drupal