Same name and namespace in other branches
  1. 8.9.x core/lib/Drupal/Core/TypedData/TypedDataInterface.php \Drupal\Core\TypedData\TypedDataInterface::getRoot()
  2. 9 core/lib/Drupal/Core/TypedData/TypedDataInterface.php \Drupal\Core\TypedData\TypedDataInterface::getRoot()

Returns the root of the typed data tree.

Returns the root data for a tree of typed data objects; e.g. for an entity field item the root of the tree is its parent entity object.

Return value

\Drupal\Core\TypedData\TraversableTypedDataInterface The root data structure, either complex data or a list.

1 method overrides TypedDataInterface::getRoot()
TypedData::getRoot in core/lib/Drupal/Core/TypedData/TypedData.php
Returns the root of the typed data tree.

File

core/lib/Drupal/Core/TypedData/TypedDataInterface.php, line 135

Class

TypedDataInterface
Interface for typed data objects.

Namespace

Drupal\Core\TypedData

Code

public function getRoot();