You are here

public function EntityListBuilder::buildOperations in Zircon Profile 8

Same name and namespace in other branches
  1. 8.0 core/lib/Drupal/Core/Entity/EntityListBuilder.php \Drupal\Core\Entity\EntityListBuilder::buildOperations()

Builds a renderable list of operation links for the entity.

Parameters

\Drupal\Core\Entity\EntityInterface $entity: The entity on which the linked operations will be performed.

Return value

array A renderable array of operation links.

See also

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

4 calls to EntityListBuilder::buildOperations()
BlockListBuilder::buildBlocksForm in core/modules/block/src/BlockListBuilder.php
Builds the main "Blocks" portion of the form.
ConfigTranslationBlockListBuilder::buildRow in core/modules/config_translation/src/Controller/ConfigTranslationBlockListBuilder.php
Builds a row for an entity in the entity listing.
EntityListBuilder::buildRow in core/lib/Drupal/Core/Entity/EntityListBuilder.php
Builds a row for an entity in the entity listing.
NodeListBuilder::buildRow in core/modules/node/src/NodeListBuilder.php
Builds a row for an entity in the entity listing.
2 methods override EntityListBuilder::buildOperations()
TestEntityListBuilder::buildOperations in core/tests/Drupal/Tests/Core/Entity/EntityListBuilderTest.php
Builds a renderable list of operation links for the entity.
TestViewListBuilder::buildOperations in core/modules/views_ui/tests/src/Unit/ViewListBuilderTest.php
Builds a renderable list of operation links for the entity.

File

core/lib/Drupal/Core/Entity/EntityListBuilder.php, line 205
Contains \Drupal\Core\Entity\EntityListBuilder.

Class

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

Namespace

Drupal\Core\Entity

Code

public function buildOperations(EntityInterface $entity) {
  $build = array(
    '#type' => 'operations',
    '#links' => $this
      ->getOperations($entity),
  );
  return $build;
}