XML-TreePP-XMLPath

 view release on metacpan or  search on metacpan

lib/XML/TreePP/XMLPath.pm  view on Meta::CPAN

        );
    print Dumper( $el );

Undesired output:

    ["\@key='val'"]

In this example of bad data being parsed, the C<boundry_stop> character C<]> was
never matched for the C<key2=val2> element.

And there is no error message. The charlexsplit method throws away the second
element silently due to the token start and stop mismatch.

=head2 Method: parseXMLPath

    use XML::TreePP::XMLPath qw(parseXMLPath);
    use Data::Dumper;
    
    my $parsedPath = parseXMLPath(
                                  q{abcdefg/xyz/path[@key1='val1'][key2='val2']/last}
                                  );



( run in 1.333 second using v1.01-cache-2.11-cpan-71847e10f99 )