You are here

public function FormatterInterface::getEntityIdFromFieldItem in Reference Table Formatter 8

The the entity ID from the field value.

Parameters

\Drupal\Core\Field\FieldItemInterface $item: The reference field to gain the ID for.

Return value

int An entity ID.

1 call to FormatterInterface::getEntityIdFromFieldItem()
FormatterBase::getEntitiesToView in src/FormatterBase.php
Get the entities which will make up the table.
2 methods override FormatterInterface::getEntityIdFromFieldItem()
EntityReference::getEntityIdFromFieldItem in src/Plugin/Field/FieldFormatter/EntityReference.php
The the entity ID from the field value.
FieldCollection::getEntityIdFromFieldItem in src/Plugin/Field/FieldFormatter/FieldCollection.php
The the entity ID from the field value.

File

src/FormatterInterface.php, line 22

Class

FormatterInterface
Interface required to implement a reference field formatter.

Namespace

Drupal\reference_table_formatter

Code

public function getEntityIdFromFieldItem(FieldItemInterface $item);