* @copyright Since 2007 PrestaShop SA and Contributors * @license https://opensource.org/licenses/OSL-3.0 Open Software License (OSL 3.0) */ namespace PrestaShop\PrestaShop\Core\Domain\CatalogPriceRule\Query; use PrestaShop\PrestaShop\Core\Domain\CatalogPriceRule\Exception\CatalogPriceRuleConstraintException; use PrestaShop\PrestaShop\Core\Domain\CatalogPriceRule\ValueObject\CatalogPriceRuleId; /** * Provides data transfer object for editing CatalogPriceRule */ class GetCatalogPriceRuleForEditing { /** * @var CatalogPriceRuleId */ private $catalogPriceRuleId; /** * @param int $catalogPriceRuleId * * @throws CatalogPriceRuleConstraintException */ public function __construct($catalogPriceRuleId) { $this->catalogPriceRuleId = new CatalogPriceRuleId($catalogPriceRuleId); } /** * @return CatalogPriceRuleId */ public function getCatalogPriceRuleId(): CatalogPriceRuleId { return $this->catalogPriceRuleId; } }