function BlockLibraryController::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/ src/ Controller/ BlockLibraryController.php, line 71
Class
- BlockLibraryController
- Provides a list of block plugins to be added to the layout.
Namespace
Drupal\block\ControllerCode
public static function create(ContainerInterface $container) {
return new static($container->get('plugin.manager.block'), $container->get('context.repository'), $container->get('current_route_match'), $container->get('plugin.manager.menu.local_action'));
}
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.