Beefy Boxes and Bandwidth Generously Provided by pair Networks
Keep It Simple, Stupid

What is the best XML module to use?

by crusty_collins (Pilgrim)
on Oct 06, 2005 at 16:24 UTC ( #497982=perlquestion: print w/replies, xml ) Need Help??
crusty_collins has asked for the wisdom of the Perl Monks concerning the following question:

O great monks, I have a new project in the planning stages that will need to read and write xml files. The xml will be simple but the files could get fairly large. I have been looking around a bit for info on which module to use... There is a LOT out there. I was thinking about using Xpath. Any suggestions? Thanks for all the advice. A good using twig web page

Replies are listed 'Best First'.
Re: What is the best XML module to use?
by GrandFather (Sage) on Oct 06, 2005 at 16:29 UTC

    Search for XML - there has been a bit of discussion of exactly that question recently. To the extent that programmers (or monks) ever come to a concensus - the answer is XML::Twig.

    Perl is Huffman encoded by design.
Re: What is the best XML module to use?
by davidrw (Prior) on Oct 06, 2005 at 16:56 UTC
    There was some discussion yesterday in the thread The mostly used xml parser ...
    but basically it just depends on your requirements.. for example XML::Simple is a good starting place, but has limits that are very clearly discussed in the pod.
Re: What is the best XML module to use?
by shady (Sexton) on Oct 06, 2005 at 17:11 UTC
    If the files expect to be large, have a look in XML::SAX. This module provides XML parsing by events, so it's make possible to parse large files without getting much of memory.

      XML::Twig is similar in that you will be able to delete elements or whole subtrees as soon as you no longer need them. XML::Twig will also fire event handlers when elements are completely parsed. I found it very easy to use.

      Take a look at the XML::Twig homepage. You will find a comparison between different XML modules and how well they are suited for different tasks.

Re: What is the best XML module to use?
by ambrus (Abbot) on Oct 06, 2005 at 20:27 UTC

Log In?

What's my password?
Create A New User
Node Status?
node history
Node Type: perlquestion [id://497982]
Approved by sunadmn
and all is quiet...

How do I use this? | Other CB clients
Other Users?
Others taking refuge in the Monastery: (6)
As of 2017-01-16 17:27 GMT
Find Nodes?
    Voting Booth?
    Do you watch meteor showers?

    Results (151 votes). Check out past polls.