public static function BlazyManagerBase::create in Blazy 8.2
Same name and namespace in other branches
- 8 src/BlazyManagerBase.php \Drupal\blazy\BlazyManagerBase::create()
File
- src/
BlazyManagerBase.php, line 97
Class
- BlazyManagerBase
- Implements BlazyManagerInterface.
Namespace
Drupal\blazyCode
public static function create(ContainerInterface $container) {
$instance = new static($container
->get('entity.repository'), $container
->get('entity_type.manager'), $container
->get('module_handler'), $container
->get('renderer'), $container
->get('config.factory'), $container
->get('cache.default'));
// @todo remove and use DI at 2.x+ post sub-classes updates.
$instance
->setRoot($container
->get('app.root'));
$instance
->setLanguageManager($container
->get('language_manager'));
return $instance;
}