12 #ifndef ZYPP_PARSER_XML_NODE_H 13 #define ZYPP_PARSER_XML_NODE_H 42 Node( xmlTextReaderPtr
const & reader_r );
45 explicit operator bool()
const 51 {
return xmlTextReaderAttributeCount(
_reader ); }
55 {
return xmlTextReaderConstBaseUri(
_reader ); }
59 {
return xmlTextReaderGetParserColumnNumber(
_reader ); }
63 {
return xmlTextReaderDepth(
_reader ); }
67 {
return xmlTextReaderConstEncoding(
_reader ); }
72 {
return XmlString( xmlTextReaderGetAttribute(
_reader, reinterpret_cast<const xmlChar *>(name_r) ),
85 {
return xmlTextReaderHasAttributes(
_reader ); }
89 {
return xmlTextReaderHasValue(
_reader ); }
93 {
return(
nodeType() == XML_READER_TYPE_ATTRIBUTE ); }
98 {
return xmlTextReaderIsDefault(
_reader ); }
102 {
return xmlTextReaderIsEmptyElement(
_reader ); }
107 {
return xmlTextReaderIsNamespaceDecl(
_reader ); }
111 {
return xmlTextReaderGetParserLineNumber(
_reader ); }
115 {
return xmlTextReaderConstLocalName(
_reader ); }
119 {
return xmlTextReaderConstName(
_reader ); }
123 {
return xmlTextReaderConstNamespaceUri(
_reader ); }
131 {
return xmlTextReaderConstPrefix(
_reader ); }
136 {
return xmlTextReaderQuoteChar(
_reader ); }
144 {
return xmlTextReaderConstValue(
_reader ); }
152 {
return xmlTextReaderConstXmlLang(
_reader ); }
156 {
return xmlTextReaderConstXmlVersion(
_reader ); }
175 #endif // ZYPP_PARSER_XML_NODE_H
XmlString getAttribute(const std::string &name_r) const
int columnNumber() const
Provide the column number of the current parsing point.
int lineNumber() const
Provide the line number of the current parsing point.
NodeType nodeType() const
Get the node type of the current node.
XmlString value() const
Provides the text value of the node if present.
xmlTextReaderPtr const & _reader
Reference to the Reader.
String related utilities and Regular expression matching.
XmlString getAttributeNo(int no_r) const
Provides a copy of the attribute value with the specified index relative to the containing element...
XmlString namespaceUri() const
The URI defining the namespace associated with the node.
XmlString prefix() const
A shorthand reference to the namespace associated with the node.
xmlTextReader based interface to Reader's current node.
XmlString getAttribute(const char *name_r) const
Provides a copy of the attribute value with the specified qualified name.
XmlString xmlVersion() const
Determine the XML version of the document being read.
int attributeCount() const
Provides the number of attributes of the current node.
bool isAttribute() const
Whether this is an Attribute node.
XmlString xmlLang() const
The xml:lang scope within which the node resides.
int isNamespaceDecl() const
Determine whether the current node is a namespace declaration rather than a regular attribute...
int depth() const
The depth of the node in the tree.
XmlString baseUri() const
The base URI of the node.
int hasValue() const
Whether the node can have a text value.
std::ostream & operator<<(std::ostream &str, const ReadState &obj)
XmlString getValue() const
Provides a copy of the text value of the node if present.
XmlString encoding() const
Determine the encoding of the document being read.
XmlString name() const
The qualified name of the node, equal to Prefix :LocalName.
int isEmptyElement() const
Check if the current node is empty.
Easy-to use interface to the ZYPP dependency resolver.
static xmlTextReaderPtr const _no_reader
NULL Reader referenced by default ctor.
xmlTextReaderMode ReadState
int isDefault() const
Whether an Attribute node was generated from the default value defined in the DTD or schema...
int quoteChar() const
The quotation mark character used to enclose the value of an attribute.
int hasAttributes() const
Whether the node has attributes.
XmlString localName() const
The local name of the node.
ReadState readState() const
Gets the read state of the reader.