Same name and namespace in other branches
- 8.9.x core/modules/block_content/src/Controller/BlockContentController.php \Drupal\block_content\Controller\BlockContentController::create()
- 9 core/modules/block_content/src/Controller/BlockContentController.php \Drupal\block_content\Controller\BlockContentController::create()
Instantiates a new instance of the implementing class using autowiring.
Parameters
\Symfony\Component\DependencyInjection\ContainerInterface $container: The service container this instance should use.
Return value
static
Overrides AutowireTrait::create
File
- core/
modules/ block_content/ src/ Controller/ BlockContentController.php, line 43
Class
Namespace
Drupal\block_content\ControllerCode
public static function create(ContainerInterface $container) {
$entity_type_manager = $container
->get('entity_type.manager');
return new static($entity_type_manager
->getStorage('block_content'), $entity_type_manager
->getStorage('block_content_type'), $container
->get('theme_handler'));
}