diff options
author | Keith Bostic <keith@wiredtiger.com> | 2013-07-29 09:54:14 -0400 |
---|---|---|
committer | Keith Bostic <keith@wiredtiger.com> | 2013-07-29 09:54:14 -0400 |
commit | 980a1c08056b28cb779fc2b35757b69a2b168619 (patch) | |
tree | 9162e439fde809a84dbb6b6dc6709a15b6b89e00 /src/docs/cursor-ops.dox | |
parent | 08c9f57a466b247206aa424eb9bd567aff37855a (diff) | |
download | mongo-980a1c08056b28cb779fc2b35757b69a2b168619.tar.gz |
Don't let snippets appear together, it looks terrible.
Diffstat (limited to 'src/docs/cursor-ops.dox')
-rw-r--r-- | src/docs/cursor-ops.dox | 15 |
1 files changed, 11 insertions, 4 deletions
diff --git a/src/docs/cursor-ops.dox b/src/docs/cursor-ops.dox index 7c40fcd5b47..eb1daac7e0d 100644 --- a/src/docs/cursor-ops.dox +++ b/src/docs/cursor-ops.dox @@ -10,10 +10,13 @@ A cursor includes: @section cursor_opening Opening a cursor -Cursors are created using the WT_SESSION::open_cursor method. The -following are examples from the example program @ex_ref{ex_cursor.c}: +Cursors are created using the WT_SESSION::open_cursor method. For +example, from the program @ex_ref{ex_cursor.c}: @snippet ex_cursor.c open cursor #1 + +Another example from the same program: + @snippet ex_cursor.c open cursor #2 In addition to traditional data sources, cursors in WiredTiger are used @@ -41,10 +44,14 @@ from the beginning or end of the data source, use the WT_CURSOR::reset method: @snippet ex_cursor.c cursor reset -To move a cursor forward or backward in the data source, use the cursor -WT_CURSOR::next and WT_CURSOR::prev methods: +To move a cursor forward in the data source, use the cursor WT_CURSOR::next +method: @snippet ex_cursor.c cursor next + +To move a cursor backward in the data source, use the cursor WT_CURSOR::prev +method: + @snippet ex_cursor.c cursor prev If the WT_CURSOR::next and WT_CURSOR::prev methods are called on cursors |