function EntityListBuilder::buildRow

Same name and namespace in other branches
  1. 8.9.x core/lib/Drupal/Core/Entity/EntityListBuilder.php \Drupal\Core\Entity\EntityListBuilder::buildRow()
  2. 10 core/lib/Drupal/Core/Entity/EntityListBuilder.php \Drupal\Core\Entity\EntityListBuilder::buildRow()
  3. 11.x core/lib/Drupal/Core/Entity/EntityListBuilder.php \Drupal\Core\Entity\EntityListBuilder::buildRow()

Builds a row for an entity in the entity listing.

Parameters

\Drupal\Core\Entity\EntityInterface $entity: The entity for this row of the list.

Return value

array A render array structure of fields for this entity.

See also

\Drupal\Core\Entity\EntityListBuilder::render()

2 calls to EntityListBuilder::buildRow()
DraggableListBuilder::buildRow in core/lib/Drupal/Core/Config/Entity/DraggableListBuilder.php
Builds a row for an entity in the entity listing.
EntityListBuilder::render in core/lib/Drupal/Core/Entity/EntityListBuilder.php
Builds the entity listing as renderable array for table.html.twig.
1 method overrides EntityListBuilder::buildRow()
DraggableListBuilder::buildRow in core/lib/Drupal/Core/Config/Entity/DraggableListBuilder.php
Builds a row for an entity in the entity listing.

File

core/lib/Drupal/Core/Entity/EntityListBuilder.php, line 174

Class

EntityListBuilder
Defines a generic implementation to build a listing of entities.

Namespace

Drupal\Core\Entity

Code

public function buildRow(EntityInterface $entity) {
  $row['operations']['data'] = $this->buildOperations($entity);
  return $row;
}

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