blob: a1833d3c76f1d040d25b8756dfa8643f0829d924 [file] [log] [blame]
<?php
#*****************************************************************************
#
# xml_sax_parsing_complement.php
#
# Author: Frédéric Jouault
# Date: 2005-11-14
#
#****************************************************************************
require_once($_SERVER['DOCUMENT_ROOT'] . "/eclipse.org-common/system/xml_sax_parsing.php");
class ComplexPropertyHandler extends SimplePropertyHandler {
var $name;
function ComplexPropertyHandler(& $owner, $property) {
parent::SimplePropertyHandler($owner, $property);
}
function & get_next($name, $attributes) {
$this->text .= "<" . $name;
foreach ($attributes as $attrName => $attrValue) {
$this->text .= " " . $attrName . "=\"" . $attrValue . "\"";
}
$this->text .=">";
$this->name = $name;
return new ComplexPropertyHandler($this, "text");
}
function set_property_value(& $value) {
$property = $this->property;
$this->owner-> $property .= $value;
}
function end($name) {
$this->text .= "</" . $name . ">";
parent::end($name);
}
}
?>