| 12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667 |
- <?php
- /**
- * 重庆赤晓店信息科技有限公司
- * https://www.chixiaodian.com
- * Copyright (c) 2023 赤店商城 All rights reserved.
- */
- abstract class PHPExcel_Worksheet_CellIterator
- {
- /**
- * PHPExcel_Worksheet to iterate
- *
- * @var PHPExcel_Worksheet
- */
- protected $subject;
- /**
- * Current iterator position
- *
- * @var mixed
- */
- protected $position = null;
- /**
- * Iterate only existing cells
- *
- * @var boolean
- */
- protected $onlyExistingCells = false;
- /**
- * Destructor
- */
- public function __destruct()
- {
- unset($this->subject);
- }
- /**
- * Get loop only existing cells
- *
- * @return boolean
- */
- public function getIterateOnlyExistingCells()
- {
- return $this->onlyExistingCells;
- }
- /**
- * Validate start/end values for "IterateOnlyExistingCells" mode, and adjust if necessary
- *
- * @throws PHPExcel_Exception
- */
- abstract protected function adjustForExistingOnlyRange();
- /**
- * Set the iterator to loop only existing cells
- *
- * @param boolean $value
- * @throws PHPExcel_Exception
- */
- public function setIterateOnlyExistingCells($value = true)
- {
- $this->onlyExistingCells = (boolean) $value;
- $this->adjustForExistingOnlyRange();
- }
- }
|