Help with traversing an XML structure

Discussion in 'Perl Misc' started by Michaelp, Aug 6, 2009.

  1. Michaelp

    Michaelp Guest

    Hello!

    I have a large number of huge XML-documents that I need to do things
    with relatively fast.

    I am trying to use the package XML::CompactTree::XS to interact with
    the (relatively simple) XML-structurem of these documents.

    (see a fragment here: http://inex.hio.no/~michaelp/test.xml )

    The package parses a tree.

    $reader = XML::LibXML::Reader->new(location => $url);
    $tree = XML::CompactTree::XS::readSubtreeToPerl($reader );

    Prettyprinting this tree with the aid of a data dumper, I get the
    following:

    >print Data::Dumper->Dump($tree);


    $VAR1 = 9;
    $VAR2 = 'UTF-8';
    $VAR3 = [
    [
    1,
    'document',
    0,
    undef,
    [
    'ARRAY(0x260eb90)',
     
    Michaelp, Aug 6, 2009
    #1
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Asad

    XML - traversing in VB

    Asad, Apr 16, 2004, in forum: ASP .Net
    Replies:
    1
    Views:
    589
    Matt Berther
    Apr 16, 2004
  2. thomson
    Replies:
    0
    Views:
    321
    thomson
    Dec 27, 2005
  3. M
    Replies:
    0
    Views:
    369
  4. Trans
    Replies:
    8
    Views:
    155
    Trans
    Apr 13, 2005
  5. ela

    traversing a hash structure

    ela, Aug 29, 2011, in forum: Perl Misc
    Replies:
    3
    Views:
    194
Loading...

Share This Page