function ListInterface::last

Returns the last item in this list.

Return value

\Drupal\Core\TypedData\TypedDataInterface|null The last item in this list, or NULL if there are no items.

1 method overrides ListInterface::last()
ItemList::last in core/lib/Drupal/Core/TypedData/Plugin/DataType/ItemList.php
Returns the last item in this list.

File

core/lib/Drupal/Core/TypedData/ListInterface.php, line 100

Class

ListInterface
Interface for a list of typed data.

Namespace

Drupal\Core\TypedData

Code

public function last() : ?TypedDataInterface;

Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.