function ListInterface::get
Same name in other branches
- 9 core/lib/Drupal/Core/TypedData/ListInterface.php \Drupal\Core\TypedData\ListInterface::get()
- 10 core/lib/Drupal/Core/TypedData/ListInterface.php \Drupal\Core\TypedData\ListInterface::get()
- 11.x core/lib/Drupal/Core/TypedData/ListInterface.php \Drupal\Core\TypedData\ListInterface::get()
Returns the item at the specified position in this list.
Parameters
int $index: Index of the item to return.
Return value
\Drupal\Core\TypedData\TypedDataInterface|null The item at the specified position in this list, or NULL if no item exists at that position.
Throws
\Drupal\Core\TypedData\Exception\MissingDataException If the complex data structure is unset and no item can be created.
1 method overrides ListInterface::get()
- ItemList::get in core/
lib/ Drupal/ Core/ TypedData/ Plugin/ DataType/ ItemList.php - Returns the item at the specified position in this list.
File
-
core/
lib/ Drupal/ Core/ TypedData/ ListInterface.php, line 57
Class
- ListInterface
- Interface for a list of typed data.
Namespace
Drupal\Core\TypedDataCode
public function get($index);
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.