NAME XML::Twig - Tree interface to XML documents allowing processing chunk by chunk of huge documents. SUMMARY (see Twig.pod for full details) single-tree mode my $t= new XML::Twig(); $t->parsefile( 'doc.xml'); $t->print; chunk mode my $t= new XML::Twig( TwigHandlers => { section => \&flush}); $t->parsefile( 'doc.xml'); $t->flush; sub flush { $_[0]->flush; } sub-tree mode # print all title's in the document my $t= new XML::Twig( TwigRoots => { title => 1 }, TwigHandlers => { title => \&list}); $t->parsefile( 'doc.xml'); sub list { print $_[1]->print . "\n"; } INSTALLATION perl Makefile.PL make make test make install CHANGES This is version 2.00 Fixed tests so they pass on Perl 5.6, using XML::Parser 2.28 Fixed bug when calling new::XML::Twig::Elt( 'CDATA'); Added check to XML::Twig::Elt paste method not to paste an element that has a parent Changed XML::Twig::Elt insert interface so a list of elements can be inserted Fixed bugs in TwigPrintOutsideRoots (the root element tags were not printed) Added XML::Twig flush_up_to and purge_up_to methods Added XML::Twig context and path methods Added XML::Twig::Elt path method Added XML::Twig::Elt replace method Added XML::Twig::Elt wrap_in method Added XML::Twig::Elt suffix method Added XML::Twig::Elt cmp. before and after methods Added XML::Twig setTwigHandlers, setTwigHandler, setStartTagHandlers, setStartTagHandler methods Added path option in TwigHandlers argument for XML::Twig::new Added path option in TwigRoots argument for XML::Twig::new AUTHOR Michel Rodriguez (m.v.rodriguez@ieee.org) The Twig page is at http://www.xmltwig.cx COPYRIGHT Copyright (c) 1999-2000, Michel Rodriguez. All Rights Reserved. This module is free software. It may be used, redistributed and/or modified under the terms of the Perl Artistic License (see http://www.perl.com/perl/misc/Artistic.html)