The XML::Grove Perl Module defines a set of objects representing XML
documents.
XML::Grove includes modules for accessing the XML objects, converting
XML content to strings, and writing XML.
XML::Grove is making it's way to CPAN at:
$CPAN/authors/id/KMACLEOD/XML-Grove-0.04.tar.gz
and is mirrored at:
ftp://ftp.uu.net/vendor/bitsko/gdo/
http://unix.hensa.ac.uk/ftp/mirrors/uunet/vendor/bitsko/gdo/
ftp://unix.hensa.ac.uk/mirrors/uunet/vendor/bitsko/gdo/
http://bitsko.slc.ut.us/~ken/perl-xml/ (slow serial line)
The last link also includes HTML copies of the PODs and additional
examples.
XML::Grove requires XML::Parser from
http://www.netheaven.com/~coopercc/xmlparser/intro.html
Changes since 0.03:
* Added support for Clark Cooper's updates to XML::Parser
* several bug fixes
There is a major, but simple to fix, backward incompatible change
using the new XML::Parser. Prior to 0.04, you would parse the XML
document and get the grove using this code:
$parser->parsefile($file_name);
$grove = $parser->{Grove};
With the new XML::Parser, the grove is returned from `parsefile',
these lines should be changed to:
$grove = $parser->parsefile($file_name);
The old method is still required with the original XML::Parser 0.0.
Ken MacLeod Email: ken@bitsko.slc.ut.us
And from the README:
XML::Grove - simple, non-validating XML objects
XML::Grove provides simple objects for parsed XML documents. The objects may be
modified but no checking is performed by XML::Grove.
XML::Grove objects do not include parsing information such as character positions or
type of tags used.
The `contents' of an XML::Grove contains the root element possibly intermixed with
processing instructions (PIs) or comments.
The `contents' of an XML::Grove::Element may contain elements (XML::Grove::Element),
character data (Perl scalars), entity references (TBD, classes of
XML::Grove::Entity), character references (TBD), processing instructions
(XML::Grove::PI), and comments (XML::Grove::Comment).
The `attributes' of an XML::Grove::Element is an hash keyed by the attribute name, each
attribute is either an array that may contain Perl scalars and entity
references, or simply a Perl scalar.
To Be Determined (TBD): XML::Grove will be expanded to support additional objects and features of XML::Parser and SGML::SP::Generic as they become available. XML::Grove is intended to remain a simple module, other modules will be used to, for example, provide more parsing info, perform validation while modifying, or be able to write the same file that was read. XML::Grove and SGML::Grove should be nearly interchangeable.