8 * This source file is subject to the new BSD license that is bundled
9 * with this package in the file LICENSE.txt.
10 * It is also available through the world-wide-web at this URL:
11 * http://framework.zend.com/license/new-bsd
12 * If you did not receive a copy of the license and are unable to
13 * obtain it through the world-wide-web, please send an email
14 * to license@zend.com so we can send you a copy immediately.
18 * @subpackage Spreadsheets
19 * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com)
20 * @license http://framework.zend.com/license/new-bsd New BSD License
25 * @see Zend_Gdata_Entry
27 require_once 'Zend/Gdata/Entry.php';
30 * @see Zend_Gdata_Spreadsheets_Extension_Cell
32 require_once 'Zend/Gdata/Spreadsheets/Extension/Cell.php';
35 * Concrete class for working with Cell entries.
39 * @subpackage Spreadsheets
40 * @copyright Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com)
41 * @license http://framework.zend.com/license/new-bsd New BSD License
43 class Zend_Gdata_Spreadsheets_CellEntry extends Zend_Gdata_Entry
46 protected $_entryClassName = 'Zend_Gdata_Spreadsheets_CellEntry';
50 * Constructs a new Zend_Gdata_Spreadsheets_CellEntry object.
51 * @param string $uri (optional)
52 * @param DOMElement $element (optional) The DOMElement on which to base this object.
54 public function __construct($element = null)
56 $this->registerAllNamespaces(Zend_Gdata_Spreadsheets::$namespaces);
57 parent::__construct($element);
60 public function getDOM($doc = null, $majorVersion = 1, $minorVersion = null)
62 $element = parent::getDOM($doc, $majorVersion, $minorVersion);
63 if ($this->_cell != null) {
64 $element->appendChild($this->_cell->getDOM($element->ownerDocument));
69 protected function takeChildFromDOM($child)
71 $absoluteNodeName = $child->namespaceURI . ':' . $child->localName;
72 switch ($absoluteNodeName) {
73 case $this->lookupNamespace('gs') . ':' . 'cell';
74 $cell = new Zend_Gdata_Spreadsheets_Extension_Cell();
75 $cell->transferFromDOM($child);
79 parent::takeChildFromDOM($child);
85 * Gets the Cell element of this Cell Entry.
86 * @return Zend_Gdata_Spreadsheets_Extension_Cell
88 public function getCell()
94 * Sets the Cell element of this Cell Entry.
95 * @param $cell Zend_Gdata_Spreadsheets_Extension_Cell $cell
97 public function setCell($cell)