Blob Blame History Raw
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=9"/>
<title>Kyoto Cabinet: kyotocabinet::BasicDB::Cursor Class Reference</title>

<link href="tabs.css" rel="stylesheet" type="text/css"/>
<link href="doxygen.css" rel="stylesheet" type="text/css" />



</head>
<body>
<div id="top"><!-- do not remove this div! -->


<div id="titlearea">
<table cellspacing="0" cellpadding="0">
 <tbody>
 <tr style="height: 56px;">
  
  
  <td style="padding-left: 0.5em;">
   <div id="projectname">Kyoto Cabinet
   
   </div>
   
  </td>
  
  
  
 </tr>
 </tbody>
</table>
</div>

<!-- Generated by Doxygen 1.7.6.1 -->
  <div id="navrow1" class="tabs">
    <ul class="tablist">
      <li><a href="index.html"><span>Main&#160;Page</span></a></li>
      <li><a href="namespaces.html"><span>Namespaces</span></a></li>
      <li class="current"><a href="annotated.html"><span>Classes</span></a></li>
      <li><a href="files.html"><span>Files</span></a></li>
    </ul>
  </div>
  <div id="navrow2" class="tabs2">
    <ul class="tablist">
      <li><a href="annotated.html"><span>Class&#160;List</span></a></li>
      <li><a href="classes.html"><span>Class&#160;Index</span></a></li>
      <li><a href="hierarchy.html"><span>Class&#160;Hierarchy</span></a></li>
      <li><a href="functions.html"><span>Class&#160;Members</span></a></li>
    </ul>
  </div>
  <div id="nav-path" class="navpath">
    <ul>
      <li class="navelem"><a class="el" href="namespacekyotocabinet.html">kyotocabinet</a>      </li>
      <li class="navelem"><a class="el" href="classkyotocabinet_1_1BasicDB.html">BasicDB</a>      </li>
      <li class="navelem"><a class="el" href="classkyotocabinet_1_1BasicDB_1_1Cursor.html">Cursor</a>      </li>
    </ul>
  </div>
</div>
<div class="header">
  <div class="summary">
<a href="#pub-methods">Public Member Functions</a>  </div>
  <div class="headertitle">
<div class="title">kyotocabinet::BasicDB::Cursor Class Reference</div>  </div>
</div><!--header-->
<div class="contents">
<!-- doxytag: class="kyotocabinet::BasicDB::Cursor" --><!-- doxytag: inherits="kyotocabinet::DB::Cursor" -->
<p>Interface of cursor to indicate a record.  
 <a href="classkyotocabinet_1_1BasicDB_1_1Cursor.html#details">More...</a></p>

<p><code>#include &lt;kcdb.h&gt;</code></p>

<p><a href="classkyotocabinet_1_1BasicDB_1_1Cursor-members.html">List of all members.</a></p>
<table class="memberdecls">
<tr><td colspan="2"><h2><a name="pub-methods"></a>
Public Member Functions</h2></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">virtual&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classkyotocabinet_1_1BasicDB_1_1Cursor.html#a0e93160f1599c0063b6db4226216cfb3">~Cursor</a> ()</td></tr>
<tr><td class="mdescLeft">&#160;</td><td class="mdescRight">Destructor.  <a href="#a0e93160f1599c0063b6db4226216cfb3"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">bool&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classkyotocabinet_1_1BasicDB_1_1Cursor.html#afcefc06f76d1790461d25dcebb09e5a2">set_value</a> (const char *vbuf, size_t vsiz, bool <a class="el" href="classkyotocabinet_1_1DB_1_1Cursor.html#a312228bd858d3091e32b65f1128faab4">step</a>=false)</td></tr>
<tr><td class="mdescLeft">&#160;</td><td class="mdescRight">Set the value of the current record.  <a href="#afcefc06f76d1790461d25dcebb09e5a2"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">bool&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classkyotocabinet_1_1BasicDB_1_1Cursor.html#ad75b1a84559d4b11077415e3c414166d">set_value_str</a> (const std::string &amp;value, bool <a class="el" href="classkyotocabinet_1_1DB_1_1Cursor.html#a312228bd858d3091e32b65f1128faab4">step</a>=false)</td></tr>
<tr><td class="mdescLeft">&#160;</td><td class="mdescRight">Set the value of the current record.  <a href="#ad75b1a84559d4b11077415e3c414166d"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">bool&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classkyotocabinet_1_1BasicDB_1_1Cursor.html#a4ff900ef9fcb20caeafc00f667cd9b43">remove</a> ()</td></tr>
<tr><td class="mdescLeft">&#160;</td><td class="mdescRight">Remove the current record.  <a href="#a4ff900ef9fcb20caeafc00f667cd9b43"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">char *&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classkyotocabinet_1_1BasicDB_1_1Cursor.html#a7777ed7c57ee0a3ad26ed14a4edbade0">get_key</a> (size_t *sp, bool <a class="el" href="classkyotocabinet_1_1DB_1_1Cursor.html#a312228bd858d3091e32b65f1128faab4">step</a>=false)</td></tr>
<tr><td class="mdescLeft">&#160;</td><td class="mdescRight">Get the key of the current record.  <a href="#a7777ed7c57ee0a3ad26ed14a4edbade0"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">bool&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classkyotocabinet_1_1BasicDB_1_1Cursor.html#a6867118e1328d3d1fed377b9905114a1">get_key</a> (std::string *key, bool <a class="el" href="classkyotocabinet_1_1DB_1_1Cursor.html#a312228bd858d3091e32b65f1128faab4">step</a>=false)</td></tr>
<tr><td class="mdescLeft">&#160;</td><td class="mdescRight">Get the key of the current record.  <a href="#a6867118e1328d3d1fed377b9905114a1"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">char *&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classkyotocabinet_1_1BasicDB_1_1Cursor.html#abb9c95de012fd7d74d9656ef76110ea1">get_value</a> (size_t *sp, bool <a class="el" href="classkyotocabinet_1_1DB_1_1Cursor.html#a312228bd858d3091e32b65f1128faab4">step</a>=false)</td></tr>
<tr><td class="mdescLeft">&#160;</td><td class="mdescRight">Get the value of the current record.  <a href="#abb9c95de012fd7d74d9656ef76110ea1"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">bool&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classkyotocabinet_1_1BasicDB_1_1Cursor.html#abf0e4f52cc050d6c73cb99bb6b43a8de">get_value</a> (std::string *value, bool <a class="el" href="classkyotocabinet_1_1DB_1_1Cursor.html#a312228bd858d3091e32b65f1128faab4">step</a>=false)</td></tr>
<tr><td class="mdescLeft">&#160;</td><td class="mdescRight">Get the value of the current record.  <a href="#abf0e4f52cc050d6c73cb99bb6b43a8de"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">char *&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classkyotocabinet_1_1BasicDB_1_1Cursor.html#a2701fe0ced7c75d4da882722cb8ed8c8">get</a> (size_t *ksp, const char **vbp, size_t *vsp, bool <a class="el" href="classkyotocabinet_1_1DB_1_1Cursor.html#a312228bd858d3091e32b65f1128faab4">step</a>=false)</td></tr>
<tr><td class="mdescLeft">&#160;</td><td class="mdescRight">Get a pair of the key and the value of the current record.  <a href="#a2701fe0ced7c75d4da882722cb8ed8c8"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">bool&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classkyotocabinet_1_1BasicDB_1_1Cursor.html#aac09279d88c1e05e636f3711a3e170ad">get</a> (std::string *key, std::string *value, bool <a class="el" href="classkyotocabinet_1_1DB_1_1Cursor.html#a312228bd858d3091e32b65f1128faab4">step</a>=false)</td></tr>
<tr><td class="mdescLeft">&#160;</td><td class="mdescRight">Get a pair of the key and the value of the current record.  <a href="#aac09279d88c1e05e636f3711a3e170ad"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">char *&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classkyotocabinet_1_1BasicDB_1_1Cursor.html#a06f91cc41a0a6e9da0cbfafbbe324732">seize</a> (size_t *ksp, const char **vbp, size_t *vsp)</td></tr>
<tr><td class="mdescLeft">&#160;</td><td class="mdescRight">Get a pair of the key and the value of the current record and remove it atomically.  <a href="#a06f91cc41a0a6e9da0cbfafbbe324732"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">bool&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classkyotocabinet_1_1BasicDB_1_1Cursor.html#a64dac43b02487f56bd41560fb2e9d965">seize</a> (std::string *key, std::string *value)</td></tr>
<tr><td class="mdescLeft">&#160;</td><td class="mdescRight">Get a pair of the key and the value of the current record and remove it atomically.  <a href="#a64dac43b02487f56bd41560fb2e9d965"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">virtual <a class="el" href="classkyotocabinet_1_1BasicDB.html">BasicDB</a> *&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classkyotocabinet_1_1BasicDB_1_1Cursor.html#a79e3904e5b10ed3d356545ed4259160e">db</a> ()=0</td></tr>
<tr><td class="mdescLeft">&#160;</td><td class="mdescRight">Get the database object.  <a href="#a79e3904e5b10ed3d356545ed4259160e"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top"><a class="el" href="classkyotocabinet_1_1BasicDB_1_1Error.html">Error</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classkyotocabinet_1_1BasicDB_1_1Cursor.html#acdf0c146386e8d9c4c55b6512401a33a">error</a> ()</td></tr>
<tr><td class="mdescLeft">&#160;</td><td class="mdescRight">Get the last happened error.  <a href="#acdf0c146386e8d9c4c55b6512401a33a"></a><br/></td></tr>
</table>
<hr/><a name="details" id="details"></a><h2>Detailed Description</h2>
<div class="textblock"><p>Interface of cursor to indicate a record. </p>
</div><hr/><h2>Constructor &amp; Destructor Documentation</h2>
<a class="anchor" id="a0e93160f1599c0063b6db4226216cfb3"></a><!-- doxytag: member="kyotocabinet::BasicDB::Cursor::~Cursor" ref="a0e93160f1599c0063b6db4226216cfb3" args="()" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">virtual <a class="el" href="classkyotocabinet_1_1BasicDB_1_1Cursor.html#a0e93160f1599c0063b6db4226216cfb3">kyotocabinet::BasicDB::Cursor::~Cursor</a> </td>
          <td>(</td>
          <td class="paramname"></td><td>)</td>
          <td><code> [virtual]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Destructor. </p>

<p>Reimplemented from <a class="el" href="classkyotocabinet_1_1DB_1_1Cursor.html#a9ac267ce1fd4ce75fd5e69604f815032">kyotocabinet::DB::Cursor</a>.</p>

<p>Reimplemented in <a class="el" href="classkyotocabinet_1_1HashDB_1_1Cursor.html#a38d9242a0fcf2aba06792dc3dbbd9adb">kyotocabinet::HashDB::Cursor</a>, <a class="el" href="classkyotocabinet_1_1PlantDB_1_1Cursor.html#a6714f26c323848a3555dff7bada533d6">kyotocabinet::PlantDB&lt; BASEDB, DBTYPE &gt;::Cursor</a>, <a class="el" href="classkyotocabinet_1_1DirDB_1_1Cursor.html#ad2f8d403c52c56f5e89af9bd76becb2e">kyotocabinet::DirDB::Cursor</a>, <a class="el" href="classkyotocabinet_1_1CacheDB_1_1Cursor.html#a8b67ecadd10bef6445e2feb1ef40771a">kyotocabinet::CacheDB::Cursor</a>, <a class="el" href="classkyotocabinet_1_1StashDB_1_1Cursor.html#a8cee3c9907e5b73b9fd8ac18c728d2dd">kyotocabinet::StashDB::Cursor</a>, <a class="el" href="classkyotocabinet_1_1ProtoDB_1_1Cursor.html#a633ee3cb02f483f94fbaee6100c958d2">kyotocabinet::ProtoDB&lt; STRMAP, DBTYPE &gt;::Cursor</a>, <a class="el" href="classkyotocabinet_1_1PolyDB_1_1Cursor.html#af937f24b8e80a33a5766f82cf4711aff">kyotocabinet::PolyDB::Cursor</a>, and <a class="el" href="classkyotocabinet_1_1TextDB_1_1Cursor.html#a1a1a0985e52e2bacd25ddce6912d2d74">kyotocabinet::TextDB::Cursor</a>.</p>

</div>
</div>
<hr/><h2>Member Function Documentation</h2>
<a class="anchor" id="afcefc06f76d1790461d25dcebb09e5a2"></a><!-- doxytag: member="kyotocabinet::BasicDB::Cursor::set_value" ref="afcefc06f76d1790461d25dcebb09e5a2" args="(const char *vbuf, size_t vsiz, bool step=false)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">bool <a class="el" href="classkyotocabinet_1_1BasicDB_1_1Cursor.html#afcefc06f76d1790461d25dcebb09e5a2">kyotocabinet::BasicDB::Cursor::set_value</a> </td>
          <td>(</td>
          <td class="paramtype">const char *&#160;</td>
          <td class="paramname"><em>vbuf</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">size_t&#160;</td>
          <td class="paramname"><em>vsiz</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">bool&#160;</td>
          <td class="paramname"><em>step</em> = <code>false</code>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td><code> [virtual]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Set the value of the current record. </p>
<dl class="params"><dt><b>Parameters:</b></dt><dd>
  <table class="params">
    <tr><td class="paramname">vbuf</td><td>the pointer to the value region. </td></tr>
    <tr><td class="paramname">vsiz</td><td>the size of the value region. </td></tr>
    <tr><td class="paramname">step</td><td>true to move the cursor to the next record, or false for no move. </td></tr>
  </table>
  </dd>
</dl>
<dl class="return"><dt><b>Returns:</b></dt><dd>true on success, or false on failure. </dd></dl>

<p>Implements <a class="el" href="classkyotocabinet_1_1DB_1_1Cursor.html#a4d1ff14d0a9035df80ea2f9960fe96b2">kyotocabinet::DB::Cursor</a>.</p>

</div>
</div>
<a class="anchor" id="ad75b1a84559d4b11077415e3c414166d"></a><!-- doxytag: member="kyotocabinet::BasicDB::Cursor::set_value_str" ref="ad75b1a84559d4b11077415e3c414166d" args="(const std::string &amp;value, bool step=false)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">bool <a class="el" href="classkyotocabinet_1_1BasicDB_1_1Cursor.html#ad75b1a84559d4b11077415e3c414166d">kyotocabinet::BasicDB::Cursor::set_value_str</a> </td>
          <td>(</td>
          <td class="paramtype">const std::string &amp;&#160;</td>
          <td class="paramname"><em>value</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">bool&#160;</td>
          <td class="paramname"><em>step</em> = <code>false</code>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td><code> [virtual]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Set the value of the current record. </p>
<dl class="note"><dt><b>Note:</b></dt><dd>Equal to the original <a class="el" href="classkyotocabinet_1_1BasicDB_1_1Cursor.html#afcefc06f76d1790461d25dcebb09e5a2" title="Set the value of the current record.">Cursor::set_value</a> method except that the parameter is std::string. </dd></dl>

<p>Implements <a class="el" href="classkyotocabinet_1_1DB_1_1Cursor.html#a1c740a07c7f15893bf5933cd6bd5e036">kyotocabinet::DB::Cursor</a>.</p>

</div>
</div>
<a class="anchor" id="a4ff900ef9fcb20caeafc00f667cd9b43"></a><!-- doxytag: member="kyotocabinet::BasicDB::Cursor::remove" ref="a4ff900ef9fcb20caeafc00f667cd9b43" args="()" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">bool <a class="el" href="classkyotocabinet_1_1BasicDB_1_1Cursor.html#a4ff900ef9fcb20caeafc00f667cd9b43">kyotocabinet::BasicDB::Cursor::remove</a> </td>
          <td>(</td>
          <td class="paramname"></td><td>)</td>
          <td><code> [virtual]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Remove the current record. </p>
<dl class="return"><dt><b>Returns:</b></dt><dd>true on success, or false on failure. </dd></dl>
<dl class="note"><dt><b>Note:</b></dt><dd>If no record corresponds to the key, false is returned. The cursor is moved to the next record implicitly. </dd></dl>

<p>Implements <a class="el" href="classkyotocabinet_1_1DB_1_1Cursor.html#a96259c03f1caeb5b475d49a87bde8efb">kyotocabinet::DB::Cursor</a>.</p>

</div>
</div>
<a class="anchor" id="a7777ed7c57ee0a3ad26ed14a4edbade0"></a><!-- doxytag: member="kyotocabinet::BasicDB::Cursor::get_key" ref="a7777ed7c57ee0a3ad26ed14a4edbade0" args="(size_t *sp, bool step=false)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">char* <a class="el" href="classkyotocabinet_1_1BasicDB_1_1Cursor.html#a7777ed7c57ee0a3ad26ed14a4edbade0">kyotocabinet::BasicDB::Cursor::get_key</a> </td>
          <td>(</td>
          <td class="paramtype">size_t *&#160;</td>
          <td class="paramname"><em>sp</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">bool&#160;</td>
          <td class="paramname"><em>step</em> = <code>false</code>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td><code> [virtual]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Get the key of the current record. </p>
<dl class="params"><dt><b>Parameters:</b></dt><dd>
  <table class="params">
    <tr><td class="paramname">sp</td><td>the pointer to the variable into which the size of the region of the return value is assigned. </td></tr>
    <tr><td class="paramname">step</td><td>true to move the cursor to the next record, or false for no move. </td></tr>
  </table>
  </dd>
</dl>
<dl class="return"><dt><b>Returns:</b></dt><dd>the pointer to the key region of the current record, or NULL on failure. </dd></dl>
<dl class="note"><dt><b>Note:</b></dt><dd>If the cursor is invalidated, NULL is returned. Because an additional zero code is appended at the end of the region of the return value, the return value can be treated as a C-style string. Because the region of the return value is allocated with the the new[] operator, it should be released with the delete[] operator when it is no longer in use. </dd></dl>

<p>Implements <a class="el" href="classkyotocabinet_1_1DB_1_1Cursor.html#aec52b1f02b71222f90c5e1dcaf6f38d7">kyotocabinet::DB::Cursor</a>.</p>

</div>
</div>
<a class="anchor" id="a6867118e1328d3d1fed377b9905114a1"></a><!-- doxytag: member="kyotocabinet::BasicDB::Cursor::get_key" ref="a6867118e1328d3d1fed377b9905114a1" args="(std::string *key, bool step=false)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">bool <a class="el" href="classkyotocabinet_1_1BasicDB_1_1Cursor.html#a7777ed7c57ee0a3ad26ed14a4edbade0">kyotocabinet::BasicDB::Cursor::get_key</a> </td>
          <td>(</td>
          <td class="paramtype">std::string *&#160;</td>
          <td class="paramname"><em>key</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">bool&#160;</td>
          <td class="paramname"><em>step</em> = <code>false</code>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td><code> [virtual]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Get the key of the current record. </p>
<dl class="note"><dt><b>Note:</b></dt><dd>Equal to the original <a class="el" href="classkyotocabinet_1_1BasicDB_1_1Cursor.html#a7777ed7c57ee0a3ad26ed14a4edbade0" title="Get the key of the current record.">Cursor::get_key</a> method except that a parameter is a string to contain the result and the return value is bool for success. </dd></dl>

<p>Implements <a class="el" href="classkyotocabinet_1_1DB_1_1Cursor.html#a2ac5f1212cc9b9dcddad1c591b44d2e2">kyotocabinet::DB::Cursor</a>.</p>

</div>
</div>
<a class="anchor" id="abb9c95de012fd7d74d9656ef76110ea1"></a><!-- doxytag: member="kyotocabinet::BasicDB::Cursor::get_value" ref="abb9c95de012fd7d74d9656ef76110ea1" args="(size_t *sp, bool step=false)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">char* <a class="el" href="classkyotocabinet_1_1BasicDB_1_1Cursor.html#abb9c95de012fd7d74d9656ef76110ea1">kyotocabinet::BasicDB::Cursor::get_value</a> </td>
          <td>(</td>
          <td class="paramtype">size_t *&#160;</td>
          <td class="paramname"><em>sp</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">bool&#160;</td>
          <td class="paramname"><em>step</em> = <code>false</code>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td><code> [virtual]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Get the value of the current record. </p>
<dl class="params"><dt><b>Parameters:</b></dt><dd>
  <table class="params">
    <tr><td class="paramname">sp</td><td>the pointer to the variable into which the size of the region of the return value is assigned. </td></tr>
    <tr><td class="paramname">step</td><td>true to move the cursor to the next record, or false for no move. </td></tr>
  </table>
  </dd>
</dl>
<dl class="return"><dt><b>Returns:</b></dt><dd>the pointer to the value region of the current record, or NULL on failure. </dd></dl>
<dl class="note"><dt><b>Note:</b></dt><dd>If the cursor is invalidated, NULL is returned. Because an additional zero code is appended at the end of the region of the return value, the return value can be treated as a C-style string. Because the region of the return value is allocated with the the new[] operator, it should be released with the delete[] operator when it is no longer in use. </dd></dl>

<p>Implements <a class="el" href="classkyotocabinet_1_1DB_1_1Cursor.html#aa00f9d9f984a17dcb8d24bbacaf573af">kyotocabinet::DB::Cursor</a>.</p>

</div>
</div>
<a class="anchor" id="abf0e4f52cc050d6c73cb99bb6b43a8de"></a><!-- doxytag: member="kyotocabinet::BasicDB::Cursor::get_value" ref="abf0e4f52cc050d6c73cb99bb6b43a8de" args="(std::string *value, bool step=false)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">bool <a class="el" href="classkyotocabinet_1_1BasicDB_1_1Cursor.html#abb9c95de012fd7d74d9656ef76110ea1">kyotocabinet::BasicDB::Cursor::get_value</a> </td>
          <td>(</td>
          <td class="paramtype">std::string *&#160;</td>
          <td class="paramname"><em>value</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">bool&#160;</td>
          <td class="paramname"><em>step</em> = <code>false</code>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td><code> [virtual]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Get the value of the current record. </p>
<dl class="note"><dt><b>Note:</b></dt><dd>Equal to the original <a class="el" href="classkyotocabinet_1_1BasicDB_1_1Cursor.html#abb9c95de012fd7d74d9656ef76110ea1" title="Get the value of the current record.">Cursor::get_value</a> method except that a parameter is a string to contain the result and the return value is bool for success. </dd></dl>

<p>Implements <a class="el" href="classkyotocabinet_1_1DB_1_1Cursor.html#a93c30a739b1ece495ee0c43d87d1525d">kyotocabinet::DB::Cursor</a>.</p>

</div>
</div>
<a class="anchor" id="a2701fe0ced7c75d4da882722cb8ed8c8"></a><!-- doxytag: member="kyotocabinet::BasicDB::Cursor::get" ref="a2701fe0ced7c75d4da882722cb8ed8c8" args="(size_t *ksp, const char **vbp, size_t *vsp, bool step=false)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">char* <a class="el" href="classkyotocabinet_1_1BasicDB_1_1Cursor.html#a2701fe0ced7c75d4da882722cb8ed8c8">kyotocabinet::BasicDB::Cursor::get</a> </td>
          <td>(</td>
          <td class="paramtype">size_t *&#160;</td>
          <td class="paramname"><em>ksp</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const char **&#160;</td>
          <td class="paramname"><em>vbp</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">size_t *&#160;</td>
          <td class="paramname"><em>vsp</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">bool&#160;</td>
          <td class="paramname"><em>step</em> = <code>false</code>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td><code> [virtual]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Get a pair of the key and the value of the current record. </p>
<dl class="params"><dt><b>Parameters:</b></dt><dd>
  <table class="params">
    <tr><td class="paramname">ksp</td><td>the pointer to the variable into which the size of the region of the return value is assigned. </td></tr>
    <tr><td class="paramname">vbp</td><td>the pointer to the variable into which the pointer to the value region is assigned. </td></tr>
    <tr><td class="paramname">vsp</td><td>the pointer to the variable into which the size of the value region is assigned. </td></tr>
    <tr><td class="paramname">step</td><td>true to move the cursor to the next record, or false for no move. </td></tr>
  </table>
  </dd>
</dl>
<dl class="return"><dt><b>Returns:</b></dt><dd>the pointer to the key region, or NULL on failure. </dd></dl>
<dl class="note"><dt><b>Note:</b></dt><dd>If the cursor is invalidated, NULL is returned. Because an additional zero code is appended at the end of each region of the key and the value, each region can be treated as a C-style string. The return value should be deleted explicitly by the caller with the detele[] operator. </dd></dl>

<p>Implements <a class="el" href="classkyotocabinet_1_1DB_1_1Cursor.html#a556bb019a558a6279e4778361e889289">kyotocabinet::DB::Cursor</a>.</p>

</div>
</div>
<a class="anchor" id="aac09279d88c1e05e636f3711a3e170ad"></a><!-- doxytag: member="kyotocabinet::BasicDB::Cursor::get" ref="aac09279d88c1e05e636f3711a3e170ad" args="(std::string *key, std::string *value, bool step=false)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">bool <a class="el" href="classkyotocabinet_1_1BasicDB_1_1Cursor.html#a2701fe0ced7c75d4da882722cb8ed8c8">kyotocabinet::BasicDB::Cursor::get</a> </td>
          <td>(</td>
          <td class="paramtype">std::string *&#160;</td>
          <td class="paramname"><em>key</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">std::string *&#160;</td>
          <td class="paramname"><em>value</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">bool&#160;</td>
          <td class="paramname"><em>step</em> = <code>false</code>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td><code> [virtual]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Get a pair of the key and the value of the current record. </p>
<dl class="note"><dt><b>Note:</b></dt><dd>Equal to the original <a class="el" href="classkyotocabinet_1_1BasicDB_1_1Cursor.html#a2701fe0ced7c75d4da882722cb8ed8c8" title="Get a pair of the key and the value of the current record.">Cursor::get</a> method except that parameters are strings to contain the result and the return value is bool for success. </dd></dl>

<p>Implements <a class="el" href="classkyotocabinet_1_1DB_1_1Cursor.html#a71ed167fd7beb149d110c3eed43be108">kyotocabinet::DB::Cursor</a>.</p>

</div>
</div>
<a class="anchor" id="a06f91cc41a0a6e9da0cbfafbbe324732"></a><!-- doxytag: member="kyotocabinet::BasicDB::Cursor::seize" ref="a06f91cc41a0a6e9da0cbfafbbe324732" args="(size_t *ksp, const char **vbp, size_t *vsp)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">char* <a class="el" href="classkyotocabinet_1_1BasicDB_1_1Cursor.html#a06f91cc41a0a6e9da0cbfafbbe324732">kyotocabinet::BasicDB::Cursor::seize</a> </td>
          <td>(</td>
          <td class="paramtype">size_t *&#160;</td>
          <td class="paramname"><em>ksp</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const char **&#160;</td>
          <td class="paramname"><em>vbp</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">size_t *&#160;</td>
          <td class="paramname"><em>vsp</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Get a pair of the key and the value of the current record and remove it atomically. </p>
<dl class="params"><dt><b>Parameters:</b></dt><dd>
  <table class="params">
    <tr><td class="paramname">ksp</td><td>the pointer to the variable into which the size of the region of the return value is assigned. </td></tr>
    <tr><td class="paramname">vbp</td><td>the pointer to the variable into which the pointer to the value region is assigned. </td></tr>
    <tr><td class="paramname">vsp</td><td>the pointer to the variable into which the size of the value region is assigned. </td></tr>
  </table>
  </dd>
</dl>
<dl class="return"><dt><b>Returns:</b></dt><dd>the pointer to the key region, or NULL on failure. </dd></dl>
<dl class="note"><dt><b>Note:</b></dt><dd>If the cursor is invalidated, NULL is returned. Because an additional zero code is appended at the end of each region of the key and the value, each region can be treated as a C-style string. The return value should be deleted explicitly by the caller with the detele[] operator. The cursor is moved to the next record implicitly. </dd></dl>

</div>
</div>
<a class="anchor" id="a64dac43b02487f56bd41560fb2e9d965"></a><!-- doxytag: member="kyotocabinet::BasicDB::Cursor::seize" ref="a64dac43b02487f56bd41560fb2e9d965" args="(std::string *key, std::string *value)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">bool <a class="el" href="classkyotocabinet_1_1BasicDB_1_1Cursor.html#a06f91cc41a0a6e9da0cbfafbbe324732">kyotocabinet::BasicDB::Cursor::seize</a> </td>
          <td>(</td>
          <td class="paramtype">std::string *&#160;</td>
          <td class="paramname"><em>key</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">std::string *&#160;</td>
          <td class="paramname"><em>value</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Get a pair of the key and the value of the current record and remove it atomically. </p>
<dl class="note"><dt><b>Note:</b></dt><dd>Equal to the original <a class="el" href="classkyotocabinet_1_1BasicDB_1_1Cursor.html#a06f91cc41a0a6e9da0cbfafbbe324732" title="Get a pair of the key and the value of the current record and remove it atomically.">Cursor::seize</a> method except that parameters are strings to contain the result and the return value is bool for success. </dd></dl>

</div>
</div>
<a class="anchor" id="a79e3904e5b10ed3d356545ed4259160e"></a><!-- doxytag: member="kyotocabinet::BasicDB::Cursor::db" ref="a79e3904e5b10ed3d356545ed4259160e" args="()=0" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">virtual <a class="el" href="classkyotocabinet_1_1BasicDB.html">BasicDB</a>* <a class="el" href="classkyotocabinet_1_1BasicDB_1_1Cursor.html#a79e3904e5b10ed3d356545ed4259160e">kyotocabinet::BasicDB::Cursor::db</a> </td>
          <td>(</td>
          <td class="paramname"></td><td>)</td>
          <td><code> [pure virtual]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Get the database object. </p>
<dl class="return"><dt><b>Returns:</b></dt><dd>the database object. </dd></dl>

<p>Implements <a class="el" href="classkyotocabinet_1_1DB_1_1Cursor.html#a20b908092afa13830cf18fd19ac19ef2">kyotocabinet::DB::Cursor</a>.</p>

<p>Implemented in <a class="el" href="classkyotocabinet_1_1HashDB_1_1Cursor.html#af4c7afcf214e27b4443a4b8a2bf10e98">kyotocabinet::HashDB::Cursor</a>, <a class="el" href="classkyotocabinet_1_1PlantDB_1_1Cursor.html#a5b1ae804863c879191b39fc432ac4e91">kyotocabinet::PlantDB&lt; BASEDB, DBTYPE &gt;::Cursor</a>, <a class="el" href="classkyotocabinet_1_1DirDB_1_1Cursor.html#ac0836d0d5f9698adc2b877635519e8cd">kyotocabinet::DirDB::Cursor</a>, <a class="el" href="classkyotocabinet_1_1CacheDB_1_1Cursor.html#a53297e2dc505eca116e97e5419686279">kyotocabinet::CacheDB::Cursor</a>, <a class="el" href="classkyotocabinet_1_1ProtoDB_1_1Cursor.html#a4fb26a2e77eafff88624c4b327a08c2c">kyotocabinet::ProtoDB&lt; STRMAP, DBTYPE &gt;::Cursor</a>, <a class="el" href="classkyotocabinet_1_1StashDB_1_1Cursor.html#a5e8436056db9fc5d20c643a745a606ac">kyotocabinet::StashDB::Cursor</a>, <a class="el" href="classkyotocabinet_1_1TextDB_1_1Cursor.html#a38e8f7defb5a7eab2ea34ff3e22e4970">kyotocabinet::TextDB::Cursor</a>, and <a class="el" href="classkyotocabinet_1_1PolyDB_1_1Cursor.html#a9adb3e84f317deba37effc1ddc6bf9fd">kyotocabinet::PolyDB::Cursor</a>.</p>

</div>
</div>
<a class="anchor" id="acdf0c146386e8d9c4c55b6512401a33a"></a><!-- doxytag: member="kyotocabinet::BasicDB::Cursor::error" ref="acdf0c146386e8d9c4c55b6512401a33a" args="()" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="classkyotocabinet_1_1BasicDB_1_1Error.html">Error</a> <a class="el" href="classkyotocabinet_1_1BasicDB_1_1Cursor.html#acdf0c146386e8d9c4c55b6512401a33a">kyotocabinet::BasicDB::Cursor::error</a> </td>
          <td>(</td>
          <td class="paramname"></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Get the last happened error. </p>
<dl class="return"><dt><b>Returns:</b></dt><dd>the last happened error. </dd></dl>

</div>
</div>
</div><!-- contents -->


<hr class="footer"/><address class="footer"><small>
Generated on Fri May 25 2012 01:21:36 for Kyoto Cabinet by &#160;<a href="http://www.doxygen.org/index.html">
<img class="footer" src="doxygen.png" alt="doxygen"/>
</a> 1.7.6.1
</small></address>

</body>
</html>