directory-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From build...@apache.org
Subject svn commit: r887915 - in /websites/staging/directory/trunk/content: ./ mavibot/user-guide/4-btree-operations.html
Date Sun, 24 Nov 2013 18:09:48 GMT
Author: buildbot
Date: Sun Nov 24 18:09:47 2013
New Revision: 887915

Log:
Staging update by buildbot for directory

Modified:
    websites/staging/directory/trunk/content/   (props changed)
    websites/staging/directory/trunk/content/mavibot/user-guide/4-btree-operations.html

Propchange: websites/staging/directory/trunk/content/
------------------------------------------------------------------------------
--- cms:source-revision (original)
+++ cms:source-revision Sun Nov 24 18:09:47 2013
@@ -1 +1 @@
-1545020
+1545023

Modified: websites/staging/directory/trunk/content/mavibot/user-guide/4-btree-operations.html
==============================================================================
--- websites/staging/directory/trunk/content/mavibot/user-guide/4-btree-operations.html (original)
+++ websites/staging/directory/trunk/content/mavibot/user-guide/4-btree-operations.html Sun
Nov 24 18:09:47 2013
@@ -146,11 +146,11 @@
 
 
 <h1 id="4-btree-operations">4 - BTree operations</h1>
-<p>We will now list all the possible operations that can be applied on a <strong>BTree</strong>.
But first, let's introduce the <em>Cursor</em> interface, as it's used by all
the <em>browse</em> operation.</p>
+<p>We will now list all the possible operations that can be applied on a <strong>BTree</strong>.
But first, let us understand the <em>Cursor</em> interface, as it's used for navigating
a <strong>BTree</strong> using various types of <em>browse</em> operations.</p>
 <h2 id="41-the-cursor-interface">4.1 The Cursor interface</h2>
-<p>All the browse operations will return a <em>Cursor</em> instance. A
<em>Cursor</em> allows one to move forward and backward on a <strong>BTree</strong>.
It starts at a specific position, and can be moved to a specific position too. The default
position for a <em>Cursor</em> is before the very first element of the <strong>BTree</strong></p>
+<p>All the <em>browse</em> operations will return a <em>Cursor</em>
instance. A <em>Cursor</em> allows navigating forward and backward on a <strong>BTree</strong>.
It starts at a specific position, and can be moved to a specific position too. The default
position for a <em>Cursor</em> is before the very first element of the <strong>BTree</strong></p>
 <DIV class="note" markdown="1">
-It's important to understand that a <b>Cursor</b> returns tuples, not keys. A
Key may be associated to many values, so a cursor may return many tuples with a given key
(each one will have a different value though).
+It's important to understand that a <b>Cursor</b> returns tuples, not keys. A
Key may be associated with many values, so a cursor may return many tuples with a given key
(each one will have a different value though).
 </DIV>
 
 <p>Here is the <strong>BTree</strong> sample we will use for the following
examples :</p>
@@ -159,34 +159,36 @@ It's important to understand that a <b>C
 <h4 id="4111-afterlast">4.1.1.1 afterLast</h4>
 <p>Moves the current position after the last element (last key and last value). The
following schema shows the new position of the pointer after having called the <em>afterLast()</em>
method :</p>
 <p><img alt="After Last" src="images/ug-btree-after-last.png" /></p>
-<p>As we can see, we are not pointing any tuple nor any key.</p>
+<p>As we can see, we are not pointing at any key.</p>
 <h4 id="4112-beforefirst">4.1.1.2 beforeFirst</h4>
 <p>Moves the current position before the first element (first key and first value).
The following schema shows the new position of the pointer after having called the <em>beforeFirst()</em>
method :</p>
 <p><img alt="Before First" src="images/ug-btree-before-first.png" /></p>
-<p>As we can see, we are not pointing any tuple nor any key.</p>
+<p>In this case also cursor is not stationed at any key.</p>
 <h3 id="412-cursor-operations">4.1.2 Cursor operations</h3>
-<p>We have to sets of methods depending on the elements we are browsing : tuples or
keys. Operations on tuples may return many tuples with the same key (actually, one per value),
when operations on keys just return one tuple containing the key and the first value for this
key.</p>
+<p>When a cursor is used to browse Tuples it may return many tuples with the same key
but different value, when used to browse keys a 
+single tuple will be returned for each key with the value of the key (when multiple values
are present only the first value will be
+returned).</p>
 <h4 id="4121-hasnext">4.1.2.1 hasNext</h4>
-<p>Tells if there is a next available tuple. This will always be true if we are before
the first tuple, and always be fore if we are on the last tuple or after the last tuple. The
following picture shows the returned value for calls in various cases :</p>
+<p>Tells if there is a next available tuple. This will always be true if we are before
the first tuple, and always false if we are on the last tuple or after the last tuple. The
following picture shows the returned value for calls in various cases :</p>
 <p><img alt="Has Next" src="images/ug-btree-has-next.png" /></p>
 <h4 id="4122-hasprev">4.1.2.2 hasPrev</h4>
-<p>Tells if there is a previous available tuple</p>
+<p>Returns true if there is a tuple available before the current tuple.</p>
 <h4 id="4123-next">4.1.2.3 next</h4>
-<p>Moves to the next value, or to the next key if all the values have been processed,
and return the associated tuple</p>
+<p>Moves to the next value of the current key or to the next key if all the values
of the current key have been processed, and return the associated tuple.</p>
 <h4 id="4124-prev">4.1.2.4 prev</h4>
-<p>Moves to the previous value, or to the next key if all the values have been processed,
and return the associated tuple</p>
+<p>Moves to the previous value of the current key or to the previous key if all the
values of the current key have been processed, and return the associated tuple.</p>
 <h4 id="4125-hasnextkey">4.1.2.5 hasNextKey</h4>
-<p>Tells if there is a next available key</p>
+<p>Tells if there is a key after the current key.</p>
 <h4 id="4126-hasprevkey">4.1.2.6 hasPrevKey</h4>
-<p>Tells if there is a previous available key</p>
+<p>Tells if there is a previous key before the current key.</p>
 <h4 id="4127-nextkey">4.1.2.7 nextKey</h4>
-<p>Moves to the next key, even if we have more values to process</p>
+<p>Moves(jumps) to the next key, even if not all values of the current key are navigated.</p>
 <h4 id="4128-prevkey">4.1.2.8 prevKey</h4>
-<p>Moves to the previous key, even if we have more values to process</p>
+<p>Moves(jumps) to the previous key, even if not all values of the current key are
navigated.</p>
 <h2 id="41-browse-operations">4.1 Browse Operations</h2>
-<p>Now that we know what the <em>Cursor</em> is about, we can describe
the various <em>browse</em> operations.</p>
+<p>Now that we know what a <em>Cursor</em> is about, we can describe the
various <em>browse</em> operations.</p>
 <h3 id="411-browse">4.1.1 browse()</h3>
-<p>This method returns a cursor wich position will be set before the first key in the
<strong>BTree</strong>. </p>
+<p>This method returns a cursor with the position set before the first key of the <strong>BTree</strong>.
</p>
 
 
     <div class="nav">



Mime
View raw message