53 if (isset($this->layer)) {
54 throw new \RuntimeException(
'Catalog Layer has been already created');
56 if (!isset($this->layersPool[$layerType])) {
57 throw new \InvalidArgumentException($layerType .
' does not belong to any registered layer');
59 $this->layer = $this->objectManager->create($this->layersPool[$layerType]);
69 if (!isset($this->layer)) {
70 $this->layer = $this->objectManager->create($this->layersPool[self::CATALOG_LAYER_CATEGORY]);
const CATALOG_LAYER_CATEGORY
const CATALOG_LAYER_SEARCH
__construct(\Magento\Framework\ObjectManagerInterface $objectManager, array $layersPool)