<?xml version="1.0" encoding="iso-8859-1"?> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "DTD/xhtml1-strict.dtd"> <html><head><title>QXmlLocator Class Reference</title><style>h3.fn,span.fn { margin-left: 1cm; text-indent: -1cm } a:link { color: #004faf; text-decoration: none } a:visited { color: #672967; text-decoration: none } td.postheader { font-family: sans-serif } tr.address { font-family: sans-serif } body { background: #ffffff; color: black; } </style></head><body><table border="0" cellpadding="0" cellspacing="0" width="100%"><tr /><td align="left" valign="top" width="32"><img align="left" border="0" height="32" src="images/rb-logo.png" width="32" /></td><td width="1">  </td><td class="postheader" valign="center"><a href="../pyqt4ref.html"><font color="#004faf">Home</font></a> · <a href="classes.html"><font color="#004faf">All Classes</font></a> · <a href="modules.html"><font color="#004faf">Modules</font></a></td></table><h1 align="center">QXmlLocator Class Reference<br /><sup><sup>[<a href="qtxml.html">QtXml</a> module]</sup></sup></h1><p>The QXmlLocator class provides the XML handler classes with information about the parsing position within a file. <a href="#details">More...</a></p> <h3>Methods</h3><ul><li><div class="fn" /><b><a href="qxmllocator.html#QXmlLocator">__init__</a></b> (<i>self</i>)</li><li><div class="fn" /><b><a href="qxmllocator.html#QXmlLocator-2">__init__</a></b> (<i>self</i>, QXmlLocator)</li><li><div class="fn" />int <b><a href="qxmllocator.html#columnNumber">columnNumber</a></b> (<i>self</i>)</li><li><div class="fn" />int <b><a href="qxmllocator.html#lineNumber">lineNumber</a></b> (<i>self</i>)</li></ul><a name="details" /><hr /><h2>Detailed Description</h2><p>The QXmlLocator class provides the XML handler classes with information about the parsing position within a file.</p> <p>The reader reports a QXmlLocator to the content handler before it starts to parse the document. This is done with the <a href="qxmlcontenthandler.html#setDocumentLocator">QXmlContentHandler.setDocumentLocator</a>() function. The handler classes can now use this locator to get the position (<a href="qxmllocator.html#lineNumber">lineNumber</a>() and <a href="qxmllocator.html#columnNumber">columnNumber</a>()) that the reader has reached.</p> <hr /><h2>Method Documentation</h2><h3 class="fn"><a name="QXmlLocator" />QXmlLocator.__init__ (<i>self</i>)</h3><p>Constructor.</p> <a name="//apple_ref/cpp/instm/QXmlLocator/~QXmlLocator" /> <h3 class="fn"><a name="QXmlLocator-2" />QXmlLocator.__init__ (<i>self</i>, <a href="qxmllocator.html">QXmlLocator</a>)</h3><h3 class="fn"><a name="columnNumber" />int QXmlLocator.columnNumber (<i>self</i>)</h3><p>This method is abstract and should be reimplemented in any sub-class.</p><p>Returns the column number (starting at 1) or -1 if there is no column number available.</p> <a name="//apple_ref/cpp/instm/QXmlLocator/lineNumber" /> <h3 class="fn"><a name="lineNumber" />int QXmlLocator.lineNumber (<i>self</i>)</h3><p>This method is abstract and should be reimplemented in any sub-class.</p><p>Returns the line number (starting at 1) or -1 if there is no line number available.</p> <p /><address><hr /><div align="center"><table border="0" cellspacing="0" width="100%"><tr class="address"><td align="left" width="25%">PyQt 4.7.4 for X11</td><td align="center" width="50%">Copyright © <a href="http://www.riverbankcomputing.com">Riverbank Computing Ltd</a> and <a href="http://www.qtsoftware.com">Nokia</a> 2010</td><td align="right" width="25%">Qt 4.6.3</td></tr></table></div></address></body></html>