mirror of
https://github.com/bdnugget/magento2.git
synced 2026-11-07 17:27:36 +00:00
111 lines
2.8 KiB
PHP
111 lines
2.8 KiB
PHP
<?php
|
|
/**
|
|
* Copyright © Magento, Inc. All rights reserved.
|
|
* See COPYING.txt for license details.
|
|
*/
|
|
namespace Magento\Rule\Model\Condition;
|
|
|
|
/**
|
|
* Constructor modification point for Magento\Catalog\Model\Layer.
|
|
*
|
|
* All context classes were introduced to allow for backwards compatible constructor modifications
|
|
* of classes that were supposed to be extended by extension developers.
|
|
*
|
|
* Do not call methods of this class directly.
|
|
*
|
|
* As Magento moves from inheritance-based APIs all such classes will be deprecated together with
|
|
* the classes they were introduced for.
|
|
*
|
|
* @api
|
|
* @deprecated 100.2.0
|
|
* @since 100.0.2
|
|
*/
|
|
class Context implements \Magento\Framework\ObjectManager\ContextInterface
|
|
{
|
|
/**
|
|
* @var \Magento\Framework\View\Asset\Repository
|
|
*/
|
|
protected $_assetRepo;
|
|
|
|
/**
|
|
* @var \Magento\Framework\Stdlib\DateTime\TimezoneInterface
|
|
*/
|
|
protected $_localeDate;
|
|
|
|
/**
|
|
* @var \Magento\Framework\View\LayoutInterface
|
|
*/
|
|
protected $_layout;
|
|
|
|
/**
|
|
* @var \Magento\Rule\Model\ConditionFactory
|
|
*/
|
|
protected $_conditionFactory;
|
|
|
|
/**
|
|
* @var \Psr\Log\LoggerInterface
|
|
*/
|
|
protected $_logger;
|
|
|
|
/**
|
|
* @param \Magento\Framework\View\Asset\Repository $assetRepo
|
|
* @param \Magento\Framework\Stdlib\DateTime\TimezoneInterface $localeDate
|
|
* @param \Magento\Framework\View\LayoutInterface $layout
|
|
* @param \Magento\Rule\Model\ConditionFactory $conditionFactory
|
|
* @param \Psr\Log\LoggerInterface $logger
|
|
*/
|
|
public function __construct(
|
|
\Magento\Framework\View\Asset\Repository $assetRepo,
|
|
\Magento\Framework\Stdlib\DateTime\TimezoneInterface $localeDate,
|
|
\Magento\Framework\View\LayoutInterface $layout,
|
|
\Magento\Rule\Model\ConditionFactory $conditionFactory,
|
|
\Psr\Log\LoggerInterface $logger
|
|
) {
|
|
$this->_assetRepo = $assetRepo;
|
|
$this->_localeDate = $localeDate;
|
|
$this->_layout = $layout;
|
|
$this->_conditionFactory = $conditionFactory;
|
|
$this->_logger = $logger;
|
|
}
|
|
|
|
/**
|
|
* @return \Magento\Framework\View\Asset\Repository
|
|
*/
|
|
public function getAssetRepository()
|
|
{
|
|
return $this->_assetRepo;
|
|
}
|
|
|
|
/**
|
|
* @return \Magento\Framework\Stdlib\DateTime\TimezoneInterface
|
|
*/
|
|
public function getLocaleDate()
|
|
{
|
|
return $this->_localeDate;
|
|
}
|
|
|
|
/**
|
|
* @return \Magento\Framework\View\LayoutInterface
|
|
*/
|
|
public function getLayout()
|
|
{
|
|
return $this->_layout;
|
|
}
|
|
|
|
/**
|
|
* @return \Magento\Rule\Model\ConditionFactory
|
|
*/
|
|
public function getConditionFactory()
|
|
{
|
|
return $this->_conditionFactory;
|
|
}
|
|
|
|
/**
|
|
* @return \Psr\Log\LoggerInterface
|
|
*/
|
|
public function getLogger()
|
|
{
|
|
return $this->_logger;
|
|
}
|
|
}
|