~oif-team/ubuntu/natty/qt4-x11/xi2.1

« back to all changes in this revision

Viewing changes to doc/html/q3asciicacheiterator.html

  • Committer: Bazaar Package Importer
  • Author(s): Adam Conrad
  • Date: 2005-08-24 04:09:09 UTC
  • Revision ID: james.westby@ubuntu.com-20050824040909-xmxe9jfr4a0w5671
Tags: upstream-4.0.0
ImportĀ upstreamĀ versionĀ 4.0.0

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
<?xml version="1.0" encoding="iso-8859-1"?>
 
2
<!DOCTYPE html
 
3
    PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "DTD/xhtml1-strict.dtd">
 
4
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
 
5
<!-- /tmp/qt-4.0.0-espenr-1119621036935/qt-x11-opensource-desktop-4.0.0/doc/src/q3asciicache.qdoc -->
 
6
<head>
 
7
    <title>Qt 4.0: Q3AsciiCacheIterator Class Reference</title>
 
8
    <style>h3.fn,span.fn { margin-left: 1cm; text-indent: -1cm; }
 
9
a:link { color: #004faf; text-decoration: none }
 
10
a:visited { color: #672967; text-decoration: none }
 
11
td.postheader { font-family: sans-serif }
 
12
tr.address { font-family: sans-serif }
 
13
body { background: #ffffff; color: black; }</style>
 
14
</head>
 
15
<body>
 
16
<table border="0" cellpadding="0" cellspacing="0" width="100%">
 
17
<tr>
 
18
<td align="left" valign="top" width="32"><img src="images/qt-logo.png" align="left" width="32" height="32" border="0" /></td>
 
19
<td width="1">&nbsp;&nbsp;</td><td class="postheader" valign="center"><a href="index.html"><font color="#004faf">Home</font></a>&nbsp;&middot; <a href="classes.html"><font color="#004faf">All&nbsp;Classes</font></a>&nbsp;&middot; <a href="mainclasses.html"><font color="#004faf">Main&nbsp;Classes</font></a>&nbsp;&middot; <a href="annotated.html"><font color="#004faf">Annotated</font></a>&nbsp;&middot; <a href="groups.html"><font color="#004faf">Grouped&nbsp;Classes</font></a>&nbsp;&middot; <a href="functions.html"><font color="#004faf">Functions</font></a></td>
 
20
<td align="right" valign="top" width="230"><img src="images/trolltech-logo.png" align="right" width="203" height="32" border="0" /></td></tr></table><h1 align="center">Q3AsciiCacheIterator Class Reference</h1>
 
21
<p>The Q3AsciiCacheIterator class provides an iterator for <a href="q3asciicache.html">Q3AsciiCache</a> collections. <a href="#details">More...</a></p>
 
22
<pre>#include &lt;Q3AsciiCacheIterator&gt;</pre><p><b>This class is part of the Qt 3 support library.</b> It is provided to keep old source code working. We strongly advise against using it in new code. See the <a href="porting4.html">Porting Guide</a> for more information.</p>
 
23
<p>Part of the <a href="qt3support.html">Qt3Support</a> module.</p>
 
24
<ul>
 
25
<li><a href="q3asciicacheiterator-members.html">List of all members, including inherited members</a></li>
 
26
</ul>
 
27
<a name="public-functions"></a>
 
28
<h3>Public Functions</h3>
 
29
<ul>
 
30
<li><div class="fn"/><b><a href="q3asciicacheiterator.html#Q3AsciiCacheIterator">Q3AsciiCacheIterator</a></b> ( const Q3AsciiCache&lt;type&gt; &amp; <i>cache</i> )</li>
 
31
<li><div class="fn"/><b><a href="q3asciicacheiterator.html#Q3AsciiCacheIterator-2">Q3AsciiCacheIterator</a></b> ( const Q3AsciiCacheIterator&lt;type&gt; &amp; <i>ci</i> )</li>
 
32
<li><div class="fn"/>bool <b><a href="q3asciicacheiterator.html#atFirst">atFirst</a></b> () const</li>
 
33
<li><div class="fn"/>bool <b><a href="q3asciicacheiterator.html#atLast">atLast</a></b> () const</li>
 
34
<li><div class="fn"/>uint <b><a href="q3asciicacheiterator.html#count">count</a></b> () const</li>
 
35
<li><div class="fn"/>type * <b><a href="q3asciicacheiterator.html#current">current</a></b> () const</li>
 
36
<li><div class="fn"/>const char * <b><a href="q3asciicacheiterator.html#currentKey">currentKey</a></b> () const</li>
 
37
<li><div class="fn"/>bool <b><a href="q3asciicacheiterator.html#isEmpty">isEmpty</a></b> () const</li>
 
38
<li><div class="fn"/>type * <b><a href="q3asciicacheiterator.html#toFirst">toFirst</a></b> ()</li>
 
39
<li><div class="fn"/>type * <b><a href="q3asciicacheiterator.html#toLast">toLast</a></b> ()</li>
 
40
<li><div class="fn"/><b><a href="q3asciicacheiterator.html#operator-type--2a">operator type *</a></b> () const</li>
 
41
<li><div class="fn"/>type * <b><a href="q3asciicacheiterator.html#operator-28-29">operator()</a></b> ()</li>
 
42
<li><div class="fn"/>type * <b><a href="q3asciicacheiterator.html#operator-2b-2b">operator++</a></b> ()</li>
 
43
<li><div class="fn"/>type * <b><a href="q3asciicacheiterator.html#operator-2b-eq">operator+=</a></b> ( uint <i>jump</i> )</li>
 
44
<li><div class="fn"/>type * <b><a href="q3asciicacheiterator.html#operator--">operator--</a></b> ()</li>
 
45
<li><div class="fn"/>type * <b><a href="q3asciicacheiterator.html#operator--eq">operator-=</a></b> ( uint <i>jump</i> )</li>
 
46
<li><div class="fn"/>Q3AsciiCacheIterator&lt;type&gt; &amp; <b><a href="q3asciicacheiterator.html#operator-eq">operator=</a></b> ( const Q3AsciiCacheIterator&lt;type&gt; &amp; <i>ci</i> )</li>
 
47
</ul>
 
48
<a name="details"></a>
 
49
<hr />
 
50
<h2>Detailed Description</h2>
 
51
<p>The Q3AsciiCacheIterator class provides an iterator for <a href="q3asciicache.html">Q3AsciiCache</a> collections.</p>
 
52
<p>Note that the traversal order is arbitrary; you are not guaranteed any particular order. If new objects are inserted into the cache while the iterator is active, the iterator may or may not see them.</p>
 
53
<p>Multiple iterators are completely independent, even when they operate on the same <a href="q3asciicache.html">Q3AsciiCache</a>. <a href="q3asciicache.html">Q3AsciiCache</a> updates all iterators that refer an item when that item is removed.</p>
 
54
<p>Q3AsciiCacheIterator provides an operator++() and an operator+=() to traverse the cache; <a href="q3asciicacheiterator.html#current">current</a>() and <a href="q3asciicacheiterator.html#currentKey">currentKey</a>() to access the current cache item and its key. It also provides <a href="q3asciicacheiterator.html#atFirst">atFirst</a>() and <a href="q3asciicacheiterator.html#atLast">atLast</a>(), which return TRUE if the iterator points to the first or last item in the cache respectively. The <a href="q3asciicacheiterator.html#isEmpty">isEmpty</a>() function returns TRUE if the cache is empty; and <a href="q3asciicacheiterator.html#count">count</a>() returns the number of items in the cache.</p>
 
55
<p>Note that <a href="q3asciicacheiterator.html#atFirst">atFirst</a>() and <a href="q3asciicacheiterator.html#atLast">atLast</a>() refer to the iterator's arbitrary ordering, not to the cache's internal least recently used list.</p>
 
56
<p>See also <a href="q3asciicache.html">Q3AsciiCache</a>.</p>
 
57
<hr />
 
58
<h2>Member Function Documentation</h2>
 
59
<h3 class="fn"><a name="Q3AsciiCacheIterator"></a>Q3AsciiCacheIterator::Q3AsciiCacheIterator ( const <a href="q3asciicache.html">Q3AsciiCache</a>&lt;type&gt; &amp; <i>cache</i> )</h3>
 
60
<p>Constructs an iterator for <i>cache</i>. The current iterator item is set to point to the first item in the <i>cache</i>.</p>
 
61
<h3 class="fn"><a name="Q3AsciiCacheIterator-2"></a>Q3AsciiCacheIterator::Q3AsciiCacheIterator ( const Q3AsciiCacheIterator&lt;type&gt; &amp; <i>ci</i> )</h3>
 
62
<p>Constructs an iterator for the same cache as <i>ci</i>. The new iterator starts at the same item as ci.<a href="q3asciicacheiterator.html#current">current</a>() but moves independently from there on.</p>
 
63
<h3 class="fn"><a name="atFirst"></a>bool Q3AsciiCacheIterator::atFirst () const</h3>
 
64
<p>Returns TRUE if the iterator points to the first item in the cache; otherwise returns FALSE. Note that this refers to the iterator's arbitrary ordering, not to the cache's internal least recently used list.</p>
 
65
<p>See also <a href="q3asciicacheiterator.html#toFirst">toFirst</a>() and <a href="q3asciicacheiterator.html#atLast">atLast</a>().</p>
 
66
<h3 class="fn"><a name="atLast"></a>bool Q3AsciiCacheIterator::atLast () const</h3>
 
67
<p>Returns TRUE if the iterator points to the last item in the cache; otherwise returns FALSE. Note that this refers to the iterator's arbitrary ordering, not to the cache's internal least recently used list.</p>
 
68
<p>See also <a href="q3asciicacheiterator.html#toLast">toLast</a>() and <a href="q3asciicacheiterator.html#atFirst">atFirst</a>().</p>
 
69
<h3 class="fn"><a name="count"></a><a href="qtglobal.html#uint-typedef">uint</a> Q3AsciiCacheIterator::count () const</h3>
 
70
<p>Returns the number of items in the cache over which this iterator operates.</p>
 
71
<p>See also <a href="q3asciicacheiterator.html#isEmpty">isEmpty</a>().</p>
 
72
<h3 class="fn"><a name="current"></a>type * Q3AsciiCacheIterator::current () const</h3>
 
73
<p>Returns a pointer to the current iterator item.</p>
 
74
<h3 class="fn"><a name="currentKey"></a>const char * Q3AsciiCacheIterator::currentKey () const</h3>
 
75
<p>Returns the key for the current iterator item.</p>
 
76
<h3 class="fn"><a name="isEmpty"></a>bool Q3AsciiCacheIterator::isEmpty () const</h3>
 
77
<p>Returns TRUE if the cache is empty, i.e. <a href="q3asciicacheiterator.html#count">count</a>() == 0; otherwise returns FALSE.</p>
 
78
<p>See also <a href="q3asciicacheiterator.html#count">count</a>().</p>
 
79
<h3 class="fn"><a name="toFirst"></a>type * Q3AsciiCacheIterator::toFirst ()</h3>
 
80
<p>Sets the iterator to point to the first item in the cache and returns a pointer to the item.</p>
 
81
<p>Sets the iterator to 0 and returns 0 if the cache is empty.</p>
 
82
<p>See also <a href="q3asciicacheiterator.html#toLast">toLast</a>() and <a href="q3asciicacheiterator.html#isEmpty">isEmpty</a>().</p>
 
83
<h3 class="fn"><a name="toLast"></a>type * Q3AsciiCacheIterator::toLast ()</h3>
 
84
<p>Sets the iterator to point to the last item in the cache and returns a pointer to the item.</p>
 
85
<p>Sets the iterator to 0 and returns 0 if the cache is empty.</p>
 
86
<p>See also <a href="q3asciicacheiterator.html#toFirst">toFirst</a>() and <a href="q3asciicacheiterator.html#isEmpty">isEmpty</a>().</p>
 
87
<h3 class="fn"><a name="operator-type--2a"></a>Q3AsciiCacheIterator::operator type * () const</h3>
 
88
<p>Cast operator. Returns a pointer to the current iterator item. Same as <a href="q3asciicacheiterator.html#current">current</a>().</p>
 
89
<h3 class="fn"><a name="operator-28-29"></a>type * Q3AsciiCacheIterator::operator() ()</h3>
 
90
<p>Makes the succeeding item current and returns the original current item.</p>
 
91
<p>If the current iterator item was the last item in the cache or if it was 0, 0 is returned.</p>
 
92
<h3 class="fn"><a name="operator-2b-2b"></a>type * Q3AsciiCacheIterator::operator++ ()</h3>
 
93
<p>Prefix ++ makes the iterator point to the item just after <a href="q3asciicacheiterator.html#current">current</a>(), and makes that the new current item for the iterator. If <a href="q3asciicacheiterator.html#current">current</a>() was the last item, operator++() returns 0.</p>
 
94
<h3 class="fn"><a name="operator-2b-eq"></a>type * Q3AsciiCacheIterator::operator+= ( <a href="qtglobal.html#uint-typedef">uint</a> <i>jump</i> )</h3>
 
95
<p>Returns the item <i>jump</i> positions after the current item, or 0 if it is beyond the last item. Makes this the current item.</p>
 
96
<h3 class="fn"><a name="operator--"></a>type * Q3AsciiCacheIterator::operator-- ()</h3>
 
97
<p>Prefix -- makes the iterator point to the item just before <a href="q3asciicacheiterator.html#current">current</a>(), and makes that the new current item for the iterator. If <a href="q3asciicacheiterator.html#current">current</a>() was the first item, operator--() returns 0.</p>
 
98
<h3 class="fn"><a name="operator--eq"></a>type * Q3AsciiCacheIterator::operator-= ( <a href="qtglobal.html#uint-typedef">uint</a> <i>jump</i> )</h3>
 
99
<p>Returns the item <i>jump</i> positions before the current item, or 0 if it is before the first item. Makes this the current item.</p>
 
100
<h3 class="fn"><a name="operator-eq"></a>Q3AsciiCacheIterator&lt;type&gt; &amp; Q3AsciiCacheIterator::operator= ( const Q3AsciiCacheIterator&lt;type&gt; &amp; <i>ci</i> )</h3>
 
101
<p>Makes this an iterator for the same cache as <i>ci</i>. The new iterator starts at the same item as ci.<a href="q3asciicacheiterator.html#current">current</a>(), but moves independently thereafter.</p>
 
102
<p /><address><hr /><div align="center">
 
103
<table width="100%" cellspacing="0" border="0"><tr class="address">
 
104
<td width="30%">Copyright &copy; 2005 <a href="trolltech.html">Trolltech</a></td>
 
105
<td width="40%" align="center"><a href="trademarks.html">Trademarks</a></td>
 
106
<td width="30%" align="right"><div align="right">Qt 4.0.0</div></td>
 
107
</tr></table></div></address></body>
 
108
</html>