
Xml::struct implements a mapping between xml and perl data structures. by default, the mapping preserves element order, so it also suits for "document-oriented" xml. in short, an xml element is represented as array reference with three parts:
[ $name => \%attributes, \@children ]
this data structure corresponds to the abstract data model of microxml
, a simplified subset of xml.
if your xml documents don't contain relevant attributes, you can also choose to map to this format:
[ $name => \@children ]
both parsing (with xml::struct::reader or function readxml) and serializing (with xml::struct::writer or function writexml) are fully based on xml::libxml, so performance is better than xml::simple and similar to xml::libxml::simple.