Magento 2 Documentation  2.3
Documentation for Magento 2 CMS v2.3 (December 2018)
ExceptionHandlerBlockFactory.php
Go to the documentation of this file.
1 <?php
7 
13 {
14  const DEFAULT_INSTANCE_NAME = \Magento\Framework\View\Element\ExceptionHandlerBlock::class;
15 
19  protected $objectManager;
20 
24  protected $instanceName;
25 
30  public function __construct(
32  $instanceName = self::DEFAULT_INSTANCE_NAME
33  ) {
34  $this->objectManager = $objectManager;
35  $this->instanceName = $instanceName;
36  }
37 
44  public function create(array $data = [])
45  {
46  return $this->objectManager->create($this->instanceName, $data);
47  }
48 }
__construct(\Magento\Framework\ObjectManagerInterface $objectManager, $instanceName=self::DEFAULT_INSTANCE_NAME)