function FieldItemDataDefinitionInterface::setFieldDefinition
Same name in other branches
- 9 core/lib/Drupal/Core/Field/TypedData/FieldItemDataDefinitionInterface.php \Drupal\Core\Field\TypedData\FieldItemDataDefinitionInterface::setFieldDefinition()
- 8.9.x core/lib/Drupal/Core/Field/TypedData/FieldItemDataDefinitionInterface.php \Drupal\Core\Field\TypedData\FieldItemDataDefinitionInterface::setFieldDefinition()
- 11.x core/lib/Drupal/Core/Field/TypedData/FieldItemDataDefinitionInterface.php \Drupal\Core\Field\TypedData\FieldItemDataDefinitionInterface::setFieldDefinition()
Sets the field item's field definition.
@internal Should not be used in user code. It allows to overwrite the item definition property of the cloned field definition.
Parameters
\Drupal\Core\Field\FieldDefinitionInterface $field_definition: The new field definition to assign to this item definition.
Return value
static The object itself for chaining.
1 method overrides FieldItemDataDefinitionInterface::setFieldDefinition()
- FieldItemDataDefinition::setFieldDefinition in core/
lib/ Drupal/ Core/ Field/ TypedData/ FieldItemDataDefinition.php - Sets the field item's field definition.
File
-
core/
lib/ Drupal/ Core/ Field/ TypedData/ FieldItemDataDefinitionInterface.php, line 35
Class
- FieldItemDataDefinitionInterface
- Interface for field item data definitions.
Namespace
Drupal\Core\Field\TypedDataCode
public function setFieldDefinition($field_definition);
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.