summaryrefslogtreecommitdiffstats
path: root/core/lib/Drupal/Core/TypedData/TypedData.php
diff options
context:
space:
mode:
authorAlex Pott2014-10-14 08:55:35 (GMT)
committerAlex Pott2014-10-14 08:55:35 (GMT)
commit221a48c14e8191d8cdcbc87ac3728719b650ff8e (patch)
treeed98e06a4e331403b028b5be2df441ad3e1cc343 /core/lib/Drupal/Core/TypedData/TypedData.php
parentb82e28d5e467d4922068a8f59382ac9970e2e92c (diff)
Issue #2346129 by tstoeckler: Introduce a TraversableTypedDataInterface and use that for typehinting instead of ArrayElement.
Diffstat (limited to 'core/lib/Drupal/Core/TypedData/TypedData.php')
-rw-r--r--core/lib/Drupal/Core/TypedData/TypedData.php6
1 files changed, 3 insertions, 3 deletions
diff --git a/core/lib/Drupal/Core/TypedData/TypedData.php b/core/lib/Drupal/Core/TypedData/TypedData.php
index b0f614c..3216d21 100644
--- a/core/lib/Drupal/Core/TypedData/TypedData.php
+++ b/core/lib/Drupal/Core/TypedData/TypedData.php
@@ -39,14 +39,14 @@ abstract class TypedData implements TypedDataInterface, PluginInspectionInterfac
/**
* The parent typed data object.
*
- * @var \Drupal\Core\TypedData\TypedDataInterface
+ * @var \Drupal\Core\TypedData\TraversableTypedDataInterface|null
*/
protected $parent;
/**
* {@inheritdoc}
*/
- public static function createInstance($definition, $name = NULL, TypedDataInterface $parent = NULL) {
+ public static function createInstance($definition, $name = NULL, TraversableTypedDataInterface $parent = NULL) {
return new static($definition, $name, $parent);
}
@@ -153,7 +153,7 @@ abstract class TypedData implements TypedDataInterface, PluginInspectionInterfac
/**
* {@inheritdoc}
*/
- public function setContext($name = NULL, TypedDataInterface $parent = NULL) {
+ public function setContext($name = NULL, TraversableTypedDataInterface $parent = NULL) {
$this->parent = $parent;
$this->name = $name;
}