Creates a new reader from a string.
Creates a new reader from an IO.
Gets the attribute content for the attribute given by name.
Gets the attribute content for the attribute given by name.
Returns attribute count of the node.
Returns the current nesting depth of the reader.
Checks if the node is an empty element.
Expands the node to a XML::Node that can be searched with XPath etc.
Expands the node to a XML::Node that can be searched with XPath etc.
Checks if the node has any attributes.
Moves to the XML::Reader::Type::ATTRIBUTE with the specified name.
Moves from the XML::Reader::Type::ATTRIBUTE to its containing XML::Reader::Type::ELEMENT.
Moves to the first XML::Reader::Type::ATTRIBUTE of the node.
Moves to the next XML::Reader::Type::ATTRIBUTE of the node.
Returns the name of the node.
Moves the reader to the next node while skipping subtrees.
Moves the reader to the next sibling node while skipping subtrees.
Returns the XML::Reader::Type of the node.
Moves the reader to the next node.
Returns the node's XML content including subtrees.
Returns the XML for the node and its content including subtrees.
Returns a reference to the underlying LibXML::XMLTextReader.
Returns the text content of the node.
Struct
Value
Object
Object
Creates a new reader from a string.
See XML::ParserOptions.default for default options.
Creates a new reader from an IO.
See XML::ParserOptions.default for default options.
Gets the attribute content for the attribute given by name. Raises KeyError if attribute is not found.
Gets the attribute content for the attribute given by name. Returns nil if attribute is not found.
Returns attribute count of the node.
Returns the current nesting depth of the reader.
Checks if the node is an empty element.
Expands the node to a XML::Node that can be searched with XPath etc. The returned XML::Node is only valid until the next call to #read.
Raises a XML::Error if the node could not be expanded.
Checks if the node has any attributes.
Moves to the XML::Reader::Type::ATTRIBUTE with the specified name.
Moves from the XML::Reader::Type::ATTRIBUTE to its containing XML::Reader::Type::ELEMENT.
Moves to the first XML::Reader::Type::ATTRIBUTE of the node.
Moves to the next XML::Reader::Type::ATTRIBUTE of the node.
Returns the name of the node.
Moves the reader to the next node while skipping subtrees.
Moves the reader to the next sibling node while skipping subtrees.
Returns the XML::Reader::Type of the node.
Moves the reader to the next node.
Returns the node's XML content including subtrees.
Returns the XML for the node and its content including subtrees.
Returns a reference to the underlying LibXML::XMLTextReader.
Returns the text content of the node.
© 2012–2020 Manas Technology Solutions.
Licensed under the Apache License, Version 2.0.
https://crystal-lang.org/api/0.35.1/XML/Reader.html