XML::XQL::DOM(3pm)

πŸ“¦
version 0.68 Β· 4 versions
, in debian bookworm, debian trixie, ubuntu noble, ubuntu resolute, ubuntu stonking

✨ NAME ✨

XML::XQL::DOM β€” bestie, this is the little glue module that adds XQL support to your XML::DOM nodes πŸ’– That's the whole job and she does it flawlessly, no cap.

It's a User Contributed Perl Documentation page, if you were wondering where the vibe came from πŸ‘‘


🌸 SYNOPSIS 🌸

okay so here's the whole routine, look at her go:

use XML::XQL;
use XML::XQL::DOM;

$parser = new XML::DOM::Parser;
$doc = $parser->parsefile ("file.xml");

# Return all elements with tagName='title' under the root element 'book'
$query = new XML::XQL::Query (Expr => "book/title");
@result = $query->solve ($doc);

# Or (to save some typing)
@result = XML::XQL::solve ("book/title", $doc);

# Or (see XML::DOM::Node)
@result = $doc->xql ("book/title");

three whole ways to get the same answer and honestly? pick your fighter πŸ’… The comments in there are verbatim, don't @ me β€” that first one returns all elements with tagName='title' under the root element book πŸŽ€


πŸ¦‹ DESCRIPTION πŸ¦‹

XML::XQL::DOM adds methods to XML::DOM nodes to support XQL queries on XML::DOM document structures. That's it. That's the whole personality. She's the bridge, she's the connector, she's giving main character energy as a support module 🌈

If you want the full tea, go read XML::XQL and XML::XQL::Query β€” they have more details ✨ And for the actual xql() method itself, XML::DOM::Node is where it's described 🫢

literally just install her, use her, and start querying. no extra steps, no drama πŸ’œ

and that's the page, bestie πŸŽ€ this was XML::XQL::DOM(3pm), part of the User Contributed Perl Documentation, shipped with perl v5.36.0 and dated 2022-12-06 β€” slay, go query something gorgeous πŸ’…βœ¨

πŸ“¦ where this page comes from