.\" -*- mode: troff; coding: utf-8 -*- .\" Automatically generated by Pod::Man v6.0.2 (Pod::Simple 3.45) .\" .\" Standard preamble: .\" ======================================================================== .de Sp \" Vertical space (when we can't use .PP) .if t .sp .5v .if n .sp .. .de Vb \" Begin verbatim text .ft CW .nf .ne \\$1 .. .de Ve \" End verbatim text .ft R .fi .. .\" \*(C` and \*(C' are quotes in nroff, nothing in troff, for use with C<>. .ie n \{\ . ds C` "" . ds C' "" 'br\} .el\{\ . ds C` . ds C' 'br\} .\" .\" Escape single quotes in literal strings from groff's Unicode transform. .ie \n(.g .ds Aq \(aq .el .ds Aq ' .\" .\" If the F register is >0, we'll generate index entries on stderr for .\" titles (.TH), headers (.SH), subsections (.SS), items (.Ip), and index .\" entries marked with X<> in POD. Of course, you'll have to process the .\" output yourself in some meaningful fashion. .\" .\" Avoid warning from groff about undefined register 'F'. .de IX .. .nr rF 0 .if \n(.g .if rF .nr rF 1 .if (\n(rF:(\n(.g==0)) \{\ . if \nF \{\ . de IX . tm Index:\\$1\t\\n%\t"\\$2" .. . if !\nF==2 \{\ . nr % 0 . nr F 2 . \} . \} .\} .rr rF .\" .\" Required to disable full justification in groff 1.23.0. .if n .ds AD l .\" ======================================================================== .\" .IX Title "XML::LibXML::NamedNodeMap 3" .TH XML::LibXML::NamedNodeMap 3 2026-05-31 "perl v5.42.2" "User Contributed Perl Documentation" .\" For nroff, turn off justification. Always turn off hyphenation; it makes .\" way too many mistakes in technical documents. .if n .ad l .nh .SH NAME XML::LibXML::NamedNodeMap \- A map for named nodes .SH SYNOPSIS .IX Header "SYNOPSIS" .Vb 2 \& use XML::LibXML; \& my $map = XML::LibXML::NamedNodeMap\->new(@nodes); \& \& my $nodes_list = $map\->nodes(); \& \& my $node_with_index_2 = $map\->item(2); \& \& my $length = $map\->length; \& my $nodes_ref = $node\->nodes() \& my $node_2 = $map\->item(2); \& my $node = $map\->getNamedItem(\*(Aqphone_number\*(Aq); \& $map\->setNamedItem($new_node) \& $map\->removeNamedItem($name) .Ve .SH DESCRIPTION .IX Header "DESCRIPTION" XML::LibXML::NamedNodeMap maps nodes\*(Aq names to nodes. .SH METHODS .IX Header "METHODS" .IP length 4 .IX Item "length" .Vb 1 \& my $length = $map\->length; .Ve .Sp Returns the number of nodes in the map. .IP nodes 4 .IX Item "nodes" .Vb 1 \& my $nodes_ref = $node\->nodes() .Ve .Sp Returns a reference to the list of nodes. .IP item 4 .IX Item "item" .Vb 1 \& my $node_2 = $map\->item(2); .Ve .Sp Returns the node with the index of the argument (starting from 0) .IP getNamedItem 4 .IX Item "getNamedItem" .Vb 1 \& my $node = $map\->getNamedItem(\*(Aqphone_number\*(Aq); .Ve .Sp Returns the node with the name. .IP setNamedItem 4 .IX Item "setNamedItem" .Vb 1 \& $map\->setNamedItem($new_node) .Ve .Sp Sets the node with the same name as \f(CW$new_node\fR to \f(CW$new_node\fR. .IP removeNamedItem 4 .IX Item "removeNamedItem" .Vb 1 \& $map\->removeNamedItem($name) .Ve .Sp Remove the item with the name \f(CW$name\fR. .IP getNamedItemNS 4 .IX Item "getNamedItemNS" \&\fINot implemented yet.\fR. .IP setNamedItemNS 4 .IX Item "setNamedItemNS" \&\fINot implemented yet.\fR. .IP removeNamedItemNS 4 .IX Item "removeNamedItemNS" \&\fINot implemented yet.\fR. .SH AUTHORS .IX Header "AUTHORS" Matt Sergeant, Christian Glahn, Petr Pajas .SH VERSION .IX Header "VERSION" 2.0213 .SH COPYRIGHT .IX Header "COPYRIGHT" 2001\-2007, AxKit.com Ltd. .PP 2002\-2006, Christian Glahn. .PP 2006\-2009, Petr Pajas. .SH LICENSE .IX Header "LICENSE" This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself.