<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/> <meta http-equiv="X-UA-Compatible" content="IE=9"/> <title>libxml++: libxml++ Reference Manual</title> <link href="tabs.css" rel="stylesheet" type="text/css"/> <script type="text/javascript" src="jquery.js"></script> <script type="text/javascript" src="dynsections.js"></script> <link href="doxygen.css" rel="stylesheet" type="text/css" /> </head> <body> <div id="top"><!-- do not remove this div, it is closed by doxygen! --> <div id="titlearea"> <table cellspacing="0" cellpadding="0"> <tbody> <tr style="height: 56px;"> <td style="padding-left: 0.5em;"> <div id="projectname">libxml++  <span id="projectnumber">2.36.0</span> </div> </td> </tr> </tbody> </table> </div> <!-- end header part --> <!-- Generated by Doxygen 1.8.1.2 --> <div id="navrow1" class="tabs"> <ul class="tablist"> <li class="current"><a href="index.html"><span>Main Page</span></a></li> <li><a href="pages.html"><span>Related Pages</span></a></li> <li><a href="namespaces.html"><span>Namespaces</span></a></li> <li><a href="annotated.html"><span>Classes</span></a></li> </ul> </div> </div><!-- top --> <div class="header"> <div class="headertitle"> <div class="title">libxml++ Reference Manual </div> </div> </div><!--header--> <div class="contents"> <div class="textblock"><h1><a class="anchor" id="description"></a> Description</h1> <p>libxml++ is a C++ wrapper for the <a href="http://xmlsoft.org/">libxml2</a> XML parser and builder library. It presents a simple C++-like API that can achieve common tasks with less code.</p> <p>See also the <a href="http://library.gnome.org/devel/libxml++-tutorial/stable/">libxml++ Tutorial</a> and the <a href="http://libxmlplusplus.sourceforge.net/">libxml++ website</a>.</p> <h1><a class="anchor" id="features"></a> Features</h1> <ul> <li><a class="el" href="classxmlpp_1_1DomParser.html" title="DOM XML parser.">xmlpp::DomParser</a>: A DOM-style parser.</li> <li><a class="el" href="classxmlpp_1_1SaxParser.html" title="SAX XML parser.">xmlpp::SaxParser</a>: A SAX-style parser.</li> <li><a class="el" href="classxmlpp_1_1TextReader.html" title="A TextReader-style XML parser.">xmlpp::TextReader</a>: An XmlTextReader-style parser.</li> <li>A hierarchy of <a class="el" href="classxmlpp_1_1Node.html" title="Represents XML Nodes.">xmlpp::Node</a> classes.</li> </ul> <h1><a class="anchor" id="basics"></a> Basic Usage</h1> <p>Include the libxml++ header: </p> <div class="fragment"><div class="line"><span class="preprocessor">#include <libxml++.h></span></div> </div><!-- fragment --><p> (You may include individual headers, such as libxml++/document.h instead.)</p> <p>If your source file is <code>program.cc</code>, you can compile it with: </p> <div class="fragment"><div class="line">g++ program.cc -o program `pkg-config --cflags --libs libxml++-2.6`</div> </div><!-- fragment --><p>Alternatively, if using autoconf, use the following in <code>configure.ac:</code> </p> <div class="fragment"><div class="line">PKG_CHECK_MODULES([LIBXMLXX], [libxml++-2.6])</div> </div><!-- fragment --><p> Then use the generated <code>LIBXMLXX_CFLAGS</code> and <code>LIBXMLXX_LIBS</code> variables in the project <code>Makefile.am</code> files. For example: </p> <div class="fragment"><div class="line">program_CPPFLAGS = $(LIBXMLXX_CFLAGS)</div> <div class="line">program_LDADD = $(LIBXMLXX_LIBS)</div> </div><!-- fragment --> </div></div><!-- contents --> <!-- start footer part --> <hr class="footer"/><address class="footer"><small> Generated on Sun Nov 4 2012 22:04:14 for libxml++ by  <a href="http://www.doxygen.org/index.html"> <img class="footer" src="doxygen.png" alt="doxygen"/> </a> 1.8.1.2 </small></address> </body> </html>