function DisplayManager::addDisplayableItem

Same name in other branches
  1. 3.x modules/phpunit_example/src/DisplayManager.php \Drupal\phpunit_example\DisplayManager::addDisplayableItem()

Add a displayable item.

Parameters

DisplayInfoInterface $item: The item to add.

File

modules/phpunit_example/src/DisplayManager.php, line 33

Class

DisplayManager
An example class to demonstrate unit testing.

Namespace

Drupal\phpunit_example

Code

public function addDisplayableItem(DisplayInfoInterface $item) {
    $this->items[$item->getDisplayName()] = $item;
}