PHPExcel_Worksheet
[ class tree: PHPExcel_Worksheet ] [ index: PHPExcel_Worksheet ] [ all elements ]

Source for file Row.php

Documentation is available at Row.php

  1. <?php
  2. /**
  3.  * PHPExcel
  4.  *
  5.  * Copyright (c) 2006 - 2011 PHPExcel
  6.  *
  7.  * This library is free software; you can redistribute it and/or
  8.  * modify it under the terms of the GNU Lesser General Public
  9.  * License as published by the Free Software Foundation; either
  10.  * version 2.1 of the License, or (at your option) any later version.
  11.  *
  12.  * This library is distributed in the hope that it will be useful,
  13.  * but WITHOUT ANY WARRANTY; without even the implied warranty of
  14.  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
  15.  * Lesser General Public License for more details.
  16.  *
  17.  * You should have received a copy of the GNU Lesser General Public
  18.  * License along with this library; if not, write to the Free Software
  19.  * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301  USA
  20.  *
  21.  * @category   PHPExcel
  22.  * @package    PHPExcel_Worksheet
  23.  * @copyright  Copyright (c) 2006 - 2011 PHPExcel (http://www.codeplex.com/PHPExcel)
  24.  * @license    http://www.gnu.org/licenses/old-licenses/lgpl-2.1.txt    LGPL
  25.  * @version    1.7.6, 2011-02-27
  26.  */
  27.  
  28.  
  29. /**
  30.  * PHPExcel_Worksheet_Row
  31.  *
  32.  * Represents a row in PHPExcel_Worksheet, used by PHPExcel_Worksheet_RowIterator
  33.  *
  34.  * @category   PHPExcel
  35.  * @package    PHPExcel_Worksheet
  36.  * @copyright  Copyright (c) 2006 - 2011 PHPExcel (http://www.codeplex.com/PHPExcel)
  37.  */
  38. {
  39.     /**
  40.      * PHPExcel_Worksheet
  41.      *
  42.      * @var PHPExcel_Worksheet 
  43.      */
  44.     private $_parent;
  45.  
  46.     /**
  47.      * Row index
  48.      *
  49.      * @var int 
  50.      */
  51.     private $_rowIndex 0;
  52.  
  53.     /**
  54.      * Create a new row
  55.      *
  56.      * @param PHPExcel_Worksheet         $parent 
  57.      * @param int                        $rowIndex 
  58.      */
  59.     public function __construct(PHPExcel_Worksheet $parent null$rowIndex 1{
  60.         // Set parent and row index
  61.         $this->_parent         $parent;
  62.         $this->_rowIndex     $rowIndex;
  63.     }
  64.  
  65.     /**
  66.      * Destructor
  67.      */
  68.     public function __destruct({
  69.         unset($this->_parent);
  70.     }
  71.  
  72.     /**
  73.      * Get row index
  74.      *
  75.      * @return int 
  76.      */
  77.     public function getRowIndex({
  78.         return $this->_rowIndex;
  79.     }
  80.  
  81.     /**
  82.      * Get cell iterator
  83.      *
  84.      * @return PHPExcel_Worksheet_CellIterator 
  85.      */
  86.     public function getCellIterator({
  87.         return new PHPExcel_Worksheet_CellIterator($this->_parent$this->_rowIndex);
  88.     }
  89. }

Documentation generated on Sun, 27 Feb 2011 16:33:47 -0800 by phpDocumentor 1.4.3