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

Breadcrumb

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

function FieldItemBase::getEntity

Overrides FieldItemInterface::getEntity

5 calls to FieldItemBase::getEntity()
ChangedItem::preSave in core/lib/Drupal/Core/Field/Plugin/Field/FieldType/ChangedItem.php
Defines custom presave behavior for field values.
DefaultLanguageItem::applyDefaultValue in core/modules/language/src/DefaultLanguageItem.php
Applies the default value.
ListItemBase::getSettableOptions in core/modules/options/src/Plugin/Field/FieldType/ListItemBase.php
Returns an array of settable values with labels for display.
PasswordItem::preSave in core/lib/Drupal/Core/Field/Plugin/Field/FieldType/PasswordItem.php
Defines custom presave behavior for field values.
PathItem::postSave in core/modules/path/src/Plugin/Field/FieldType/PathItem.php
Defines custom post-save behavior for field values.

File

core/lib/Drupal/Core/Field/FieldItemBase.php, line 74

Class

FieldItemBase
An entity field item.

Namespace

Drupal\Core\Field

Code

public function getEntity() {
    return $this->getParent()
        ->getEntity();
}

API Navigation

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