Anonymous Monk has asked for the wisdom of the Perl Monks concerning the following question:
I m learning to parse XML data using XML::LibXML::Reader. Is there a way to get the total number of nodes contained in the entire XML file of a particular element? My goal is to prompt the user of the advancement of the parsing process. To do this I need to know how many values will be in my while loop.
my $entry_pattern = 'XML::LibXML::Pattern'->new('/martif/text/body +/Entry'); while ($reader->nextPatternMatch($entry_pattern)) { ...
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: XML::LibXML::Reader get size
by choroba (Cardinal) on Apr 26, 2018 at 21:36 UTC | |
by Anonymous Monk on Apr 27, 2018 at 17:09 UTC | |
by Anonymous Monk on Apr 27, 2018 at 13:08 UTC |