diff -r 5b37998e522e -r 162c1de6545a web/lib/Zend/XmlRpc/Generator/DomDocument.php --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/web/lib/Zend/XmlRpc/Generator/DomDocument.php Fri Mar 11 15:05:35 2011 +0100 @@ -0,0 +1,101 @@ +_dom->createElement($name); + + $this->_currentElement = $this->_currentElement->appendChild($newElement); + } + + /** + * Write XML text data into the currently opened XML element + * + * @param string $text + */ + protected function _writeTextData($text) + { + $this->_currentElement->appendChild($this->_dom->createTextNode($text)); + } + + /** + * Close an previously opened XML element + * + * Resets $_currentElement to the next parent node in the hierarchy + * + * @param string $name + * @return void + */ + protected function _closeElement($name) + { + if (isset($this->_currentElement->parentNode)) { + $this->_currentElement = $this->_currentElement->parentNode; + } + } + + /** + * Save XML as a string + * + * @return string + */ + public function saveXml() + { + return $this->_dom->saveXml(); + } + + /** + * Initializes internal objects + * + * @return void + */ + protected function _init() + { + $this->_dom = new DOMDocument('1.0', $this->_encoding); + $this->_currentElement = $this->_dom; + } +} \ No newline at end of file