You are here

private function EckContentController::getBundleStorage in Entity Construction Kit (ECK) 8

Retrieves the bundle storage for the given entity type.

Parameters

\Drupal\eck\EckEntityTypeInterface $eck_entity_type: The entity type.

Return value

\Drupal\Core\Entity\EntityStorageInterface The bundle storage.

2 calls to EckContentController::getBundleStorage()
EckContentController::add in src/Controller/EckContentController.php
Provides the entity submission form.
EckContentController::addPage in src/Controller/EckContentController.php
Displays add content link for available entity types.

File

src/Controller/EckContentController.php, line 138

Class

EckContentController
Provides a content controller for entities.

Namespace

Drupal\eck\Controller

Code

private function getBundleStorage(EckEntityTypeInterface $eck_entity_type) {
  $entityTypeBundle = "{$eck_entity_type->id()}_type";
  $bundleStorage = $this
    ->entityTypeManager()
    ->getStorage($entityTypeBundle);
  return $bundleStorage;
}