Server IP : 80.87.202.40 / Your IP : 216.73.216.169 Web Server : Apache System : Linux rospirotorg.ru 5.14.0-539.el9.x86_64 #1 SMP PREEMPT_DYNAMIC Thu Dec 5 22:26:13 UTC 2024 x86_64 User : bitrix ( 600) PHP Version : 8.2.27 Disable Function : NONE MySQL : OFF | cURL : ON | WGET : ON | Perl : ON | Python : OFF | Sudo : ON | Pkexec : ON Directory : /home/bitrix/ext_www/rospirotorg.ru/bitrix/modules/yandex.market/lib/result/ |
Upload File : |
<?php namespace Yandex\Market\Result; use Yandex\Market; class StepCount extends Base { protected $countList; protected $countWarnings; protected $countErrors; public function __construct() { parent::__construct(); $this->countList = []; $this->countWarnings = []; $this->countErrors = []; } public function setCount($key, $value) { $this->countList[$key] = $value; } public function hasCount($key) { return isset($this->countList[$key]); } public function getCount($key) { return isset($this->countList[$key]) ? $this->countList[$key] : null; } public function getCountList() { return $this->countList; } public function addCountWarning($key, Market\Error\Base $warning) { $this->countWarnings[$key] = $warning; $this->addWarning($warning); } public function getCountWarning($key) { return isset($this->countWarnings[$key]) ? $this->countWarnings[$key] : null; } public function addCountError($key, Market\Error\Base $error) { $this->countErrors[$key] = $error; $this->addError($error); } public function getCountError($key) { return isset($this->countErrors[$key]) ? $this->countErrors[$key] : null; } public function getSum() { return array_sum($this->countList); } }