Sophie

Sophie

distrib > Mageia > 4 > i586 > by-pkgid > 28b9e36e96ce34b2567ae5b47a27b2c5 > files > 920

python-qt4-doc-4.10.3-3.mga4.noarch.rpm

<?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>QPersistentModelIndex 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">&#160;&#160;</td><td class="postheader" valign="center"><a href="index.html"><font color="#004faf">Home</font></a>&#160;&#183; <a href="classes.html"><font color="#004faf">All Classes</font></a>&#160;&#183; <a href="modules.html"><font color="#004faf">Modules</font></a></td></table><h1 align="center">QPersistentModelIndex Class Reference<br /><sup><sup>[<a href="qtcore.html">QtCore</a> module]</sup></sup></h1><p>The QPersistentModelIndex class is used to locate data in a data
model. <a href="#details">More...</a></p>

<h3>Methods</h3><ul><li><div class="fn" /><b><a href="qpersistentmodelindex.html#QPersistentModelIndex">__init__</a></b> (<i>self</i>)</li><li><div class="fn" /><b><a href="qpersistentmodelindex.html#QPersistentModelIndex-2">__init__</a></b> (<i>self</i>, QModelIndex&#160;<i>index</i>)</li><li><div class="fn" /><b><a href="qpersistentmodelindex.html#QPersistentModelIndex-3">__init__</a></b> (<i>self</i>, QPersistentModelIndex&#160;<i>other</i>)</li><li><div class="fn" />QModelIndex <b><a href="qpersistentmodelindex.html#child">child</a></b> (<i>self</i>, int&#160;<i>row</i>, int&#160;<i>column</i>)</li><li><div class="fn" />int <b><a href="qpersistentmodelindex.html#column">column</a></b> (<i>self</i>)</li><li><div class="fn" />QVariant <b><a href="qpersistentmodelindex.html#data">data</a></b> (<i>self</i>, int&#160;<i>role</i>&#160;=&#160;Qt.DisplayRole)</li><li><div class="fn" />Qt.ItemFlags <b><a href="qpersistentmodelindex.html#flags">flags</a></b> (<i>self</i>)</li><li><div class="fn" />bool <b><a href="qpersistentmodelindex.html#isValid">isValid</a></b> (<i>self</i>)</li><li><div class="fn" />QAbstractItemModel <b><a href="qpersistentmodelindex.html#model">model</a></b> (<i>self</i>)</li><li><div class="fn" />QModelIndex <b><a href="qpersistentmodelindex.html#parent">parent</a></b> (<i>self</i>)</li><li><div class="fn" />int <b><a href="qpersistentmodelindex.html#row">row</a></b> (<i>self</i>)</li><li><div class="fn" />QModelIndex <b><a href="qpersistentmodelindex.html#sibling">sibling</a></b> (<i>self</i>, int&#160;<i>row</i>, int&#160;<i>column</i>)</li></ul><h3>Special Methods</h3><ul><li><div class="fn" />bool <b><a href="qpersistentmodelindex.html#__eq__">__eq__</a></b> (<i>self</i>, QPersistentModelIndex&#160;<i>other</i>)</li><li><div class="fn" />bool <b><a href="qpersistentmodelindex.html#__eq__-2">__eq__</a></b> (<i>self</i>, QModelIndex&#160;<i>other</i>)</li><li><div class="fn" />bool <b><a href="qpersistentmodelindex.html#__ge__">__ge__</a></b> (<i>self</i>, QPersistentModelIndex&#160;<i>other</i>)</li><li><div class="fn" />int <b><a href="qpersistentmodelindex.html#__hash__">__hash__</a></b> (<i>self</i>)</li><li><div class="fn" />bool <b><a href="qpersistentmodelindex.html#__lt__">__lt__</a></b> (<i>self</i>, QPersistentModelIndex&#160;<i>other</i>)</li><li><div class="fn" />bool <b><a href="qpersistentmodelindex.html#__ne__">__ne__</a></b> (<i>self</i>, QPersistentModelIndex&#160;<i>other</i>)</li><li><div class="fn" />bool <b><a href="qpersistentmodelindex.html#__ne__-2">__ne__</a></b> (<i>self</i>, QModelIndex&#160;<i>other</i>)</li></ul><a name="details" /><hr /><h2>Detailed Description</h2><p>The QPersistentModelIndex class is used to locate data in a data
model.</p>
<p>A QPersistentModelIndex is a model index that can be stored by
an application, and later used to access information in a model.
Unlike the <a href="qmodelindex.html">QModelIndex</a> class, it is
safe to store a QPersistentModelIndex since the model will ensure
that references to items will continue to be valid as long as they
can be accessed by the model.</p>
<p>It is good practice to check that persistent model indexes are
valid before using them.</p>
<hr /><h2>Method Documentation</h2><h3 class="fn"><a name="QPersistentModelIndex" />QPersistentModelIndex.__init__ (<i>self</i>)</h3><p>Creates a new <a href="qpersistentmodelindex.html">QPersistentModelIndex</a> that is a
copy of the model <i>index</i>.</p>


<h3 class="fn"><a name="QPersistentModelIndex-2" />QPersistentModelIndex.__init__ (<i>self</i>, <a href="qmodelindex.html">QModelIndex</a>&#160;<i>index</i>)</h3><h3 class="fn"><a name="QPersistentModelIndex-3" />QPersistentModelIndex.__init__ (<i>self</i>, <a href="qpersistentmodelindex.html">QPersistentModelIndex</a>&#160;<i>other</i>)</h3><p>Creates a new <a href="qpersistentmodelindex.html">QPersistentModelIndex</a> that is a
copy of the <i>other</i> persistent model index.</p>


<h3 class="fn"><a name="child" /><a href="qmodelindex.html">QModelIndex</a> QPersistentModelIndex.child (<i>self</i>, int&#160;<i>row</i>, int&#160;<i>column</i>)</h3><p>Returns the child of the model index that is stored in the given
<i>row</i> and <i>column</i>.</p>
<p><b>See also</b> <a href="qpersistentmodelindex.html#parent">parent</a>() and <a href="qpersistentmodelindex.html#sibling">sibling</a>().</p>


<h3 class="fn"><a name="column" />int QPersistentModelIndex.column (<i>self</i>)</h3><p>Returns the column this persistent model index refers to.</p>


<h3 class="fn"><a name="data" />QVariant QPersistentModelIndex.data (<i>self</i>, int&#160;<i>role</i>&#160;=&#160;Qt.DisplayRole)</h3><p>Returns the data for the given <i>role</i> for the item referred
to by the index.</p>
<p><b>See also</b> <a href="qt.html#ItemDataRole-enum">Qt.ItemDataRole</a> and <a href="qabstractitemmodel.html#setData">QAbstractItemModel.setData</a>().</p>


<h3 class="fn"><a name="flags" /><a href="qt-itemflags.html">Qt.ItemFlags</a> QPersistentModelIndex.flags (<i>self</i>)</h3><p>Returns the flags for the item referred to by the index.</p>
<p>This function was introduced in Qt 4.2.</p>


<h3 class="fn"><a name="isValid" />bool QPersistentModelIndex.isValid (<i>self</i>)</h3><p>Returns true if this persistent model index is valid; otherwise
returns false.</p>
<p>A valid index belongs to a model, and has non-negative row and
column numbers.</p>
<p><b>See also</b> <a href="qpersistentmodelindex.html#model">model</a>(), <a href="qpersistentmodelindex.html#row">row</a>(), and <a href="qpersistentmodelindex.html#column">column</a>().</p>


<h3 class="fn"><a name="model" /><a href="qabstractitemmodel.html">QAbstractItemModel</a> QPersistentModelIndex.model (<i>self</i>)</h3><p>Returns the model that the index belongs to.</p>


<h3 class="fn"><a name="parent" /><a href="qmodelindex.html">QModelIndex</a> QPersistentModelIndex.parent (<i>self</i>)</h3><p>Returns the parent <a href="qmodelindex.html">QModelIndex</a>
for this persistent index, or an invalid <a href="qmodelindex.html">QModelIndex</a> if it has no parent.</p>
<p><b>See also</b> <a href="qpersistentmodelindex.html#child">child</a>(), <a href="qpersistentmodelindex.html#sibling">sibling</a>(), and <a href="qpersistentmodelindex.html#model">model</a>().</p>


<h3 class="fn"><a name="row" />int QPersistentModelIndex.row (<i>self</i>)</h3><p>Returns the row this persistent model index refers to.</p>


<h3 class="fn"><a name="sibling" /><a href="qmodelindex.html">QModelIndex</a> QPersistentModelIndex.sibling (<i>self</i>, int&#160;<i>row</i>, int&#160;<i>column</i>)</h3><p>Returns the sibling at <i>row</i> and <i>column</i> or an
invalid <a href="qmodelindex.html">QModelIndex</a> if there is no
sibling at this position.</p>
<p><b>See also</b> <a href="qpersistentmodelindex.html#parent">parent</a>() and <a href="qpersistentmodelindex.html#child">child</a>().</p>


<h3 class="fn"><a name="__eq__" />bool QPersistentModelIndex.__eq__ (<i>self</i>, <a href="qpersistentmodelindex.html">QPersistentModelIndex</a>&#160;<i>other</i>)</h3><h3 class="fn"><a name="__eq__-2" />bool QPersistentModelIndex.__eq__ (<i>self</i>, <a href="qmodelindex.html">QModelIndex</a>&#160;<i>other</i>)</h3><h3 class="fn"><a name="__ge__" />bool QPersistentModelIndex.__ge__ (<i>self</i>, <a href="qpersistentmodelindex.html">QPersistentModelIndex</a>&#160;<i>other</i>)</h3><h3 class="fn"><a name="__hash__" />int QPersistentModelIndex.__hash__ (<i>self</i>)</h3><h3 class="fn"><a name="__lt__" />bool QPersistentModelIndex.__lt__ (<i>self</i>, <a href="qpersistentmodelindex.html">QPersistentModelIndex</a>&#160;<i>other</i>)</h3><h3 class="fn"><a name="__ne__" />bool QPersistentModelIndex.__ne__ (<i>self</i>, <a href="qpersistentmodelindex.html">QPersistentModelIndex</a>&#160;<i>other</i>)</h3><h3 class="fn"><a name="__ne__-2" />bool QPersistentModelIndex.__ne__ (<i>self</i>, <a href="qmodelindex.html">QModelIndex</a>&#160;<i>other</i>)</h3><address><hr /><div align="center"><table border="0" cellspacing="0" width="100%"><tr class="address"><td align="left" width="25%">PyQt&#160;4.10.3 for X11</td><td align="center" width="50%">Copyright &#169; <a href="http://www.riverbankcomputing.com">Riverbank&#160;Computing&#160;Ltd</a> and <a href="http://www.qtsoftware.com">Nokia</a> 2012</td><td align="right" width="25%">Qt&#160;4.8.5</td></tr></table></div></address></body></html>