![]() Server : Apache System : Linux server2.corals.io 4.18.0-348.2.1.el8_5.x86_64 #1 SMP Mon Nov 15 09:17:08 EST 2021 x86_64 User : corals ( 1002) PHP Version : 7.4.33 Disable Function : exec,passthru,shell_exec,system Directory : /home/corals/old/vendor/magento/module-quote/Model/Quote/Item/ |
<?php /** * Copyright © Magento, Inc. All rights reserved. * See COPYING.txt for license details. */ namespace Magento\Quote\Model\Quote\Item; use Magento\Framework\App\ObjectManager; use Magento\Framework\ObjectManager\ConfigInterface; /** * @deprecated 100.1.0 */ class CartItemProcessorsPool { /** * @var CartItemProcessorInterface[] */ private $cartItemProcessors = []; /** * @var ConfigInterface */ private $objectManagerConfig; /** * @param ConfigInterface $objectManagerConfig * @deprecated 100.1.0 */ public function __construct(ConfigInterface $objectManagerConfig) { $this->objectManagerConfig = $objectManagerConfig; } /** * @return CartItemProcessorInterface[] * @deprecated 100.1.0 */ public function getCartItemProcessors() { if (!empty($this->cartItemProcessors)) { return $this->cartItemProcessors; } $typePreference = $this->objectManagerConfig->getPreference(Repository::class); $arguments = $this->objectManagerConfig->getArguments($typePreference); if (isset($arguments['cartItemProcessors'])) { // Workaround for compiled mode. $processors = isset($arguments['cartItemProcessors']['_vac_']) ? $arguments['cartItemProcessors']['_vac_'] : $arguments['cartItemProcessors']; foreach ($processors as $name => $processor) { $className = isset($processor['instance']) ? $processor['instance'] : $processor['_i_']; $this->cartItemProcessors[$name] = ObjectManager::getInstance()->get($className); } } return $this->cartItemProcessors; } }