openlayers-8.x-4.x-dev/src/Controller/OpenlayersInteractionListBuilder.php
src/Controller/OpenlayersInteractionListBuilder.php
<?php
namespace Drupal\openlayers\Controller;
use Drupal\Core\Config\Entity\ConfigEntityListBuilder;
use Drupal\Core\Entity\EntityInterface;
/**
* Provides a listing of Openalyers Interaction configuration entities.
*/
class OpenlayersInteractionListBuilder extends ConfigEntityListBuilder {
/**
* {@inheritdoc}
*/
public function buildHeader() {
$header['label'] = $this->t('Interaction');
$header['id'] = $this->t('Machine name');
$header['service'] = $this->t('Factory service');
return $header + parent::buildHeader();
}
/**
* {@inheritdoc}
*/
public function buildRow(EntityInterface $entity) {
$row['label'] = $entity->label();
$row['id'] = $entity->id();
$row['service'] = $entity->service();
return $row + parent::buildRow($entity);
}
}