XML::TinyXML::Node - Tinyxml Node object
use XML::TinyXML::Node;
$node = XML::TinyXML::Node->new("child", "somevalue", { attribute => "value" });
$attr = $node->getAttribute("attribute");
or
$attr = $node->getAttribute(1); # attribute at index 1
or
@attrs = $node->getAttributes(); # returns all attributes in the node
Node representation for the TinyXML API
- •
- _attr
Reference to the underlying XmlNodeAttributePtr object (which
is a binding to the XmlNode C structure)
- new ($attr)
- Wrap the XmlNodeAttributePtr C structure exposing accessor to its
members
- name ([$newName])
- Get/Set the name of the attribute
- value ([$newValue])
- Get/Set the value of the attribute
- node (])
- Get the XML::TinyXML::Node to which this attribute belongs
- path ()
- Returns the unique path identifying this attribute
(can be used in xpath expressions)
- type ()
- Returns the type of this node
(at the moment it will return always the string :
"ATTRIBUTE"
which can be used to distinguish attribute-nodes from xml-nodes
in @sets returned by xpath selections)
XML::TinyXML::Node XML::TinyXML
Copyright (C) 2008-2010 by xant
This library is free software; you can redistribute it and/or
modify it under the same terms as Perl itself, either Perl version 5.8.8 or,
at your option, any later version of Perl 5 you may have available.