1<?xml version="1.0" encoding="UTF-8" standalone="no"?> 2<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> 3<html xmlns="http://www.w3.org/1999/xhtml"> 4 <head> 5 <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /> 6 <title>Chapter��6.�� The DB_LOCK Handle</title> 7 <link rel="stylesheet" href="apiReference.css" type="text/css" /> 8 <meta name="generator" content="DocBook XSL Stylesheets V1.73.2" /> 9 <link rel="start" href="index.html" title="Berkeley DB C API Reference" /> 10 <link rel="up" href="index.html" title="Berkeley DB C API Reference" /> 11 <link rel="prev" href="envversion.html" title="db_version" /> 12 <link rel="next" href="envget_lk_conflicts.html" title="DB_ENV->get_lk_conflicts()" /> 13 </head> 14 <body> 15 <div class="navheader"> 16 <table width="100%" summary="Navigation header"> 17 <tr> 18 <th colspan="3" align="center">Chapter��6.�� 19 The DB_LOCK Handle 20 </th> 21 </tr> 22 <tr> 23 <td width="20%" align="left"><a accesskey="p" href="envversion.html">Prev</a>��</td> 24 <th width="60%" align="center">��</th> 25 <td width="20%" align="right">��<a accesskey="n" href="envget_lk_conflicts.html">Next</a></td> 26 </tr> 27 </table> 28 <hr /> 29 </div> 30 <div class="chapter" lang="en" xml:lang="en"> 31 <div class="titlepage"> 32 <div> 33 <div> 34 <h2 class="title"><a id="lock"></a>Chapter��6.�� 35 The DB_LOCK Handle 36 </h2> 37 </div> 38 </div> 39 </div> 40 <pre class="programlisting">#include <db.h> 41 42typedef struct __db_lock_u DB_LOCK; </pre> 43 <p> 44 The locking interfaces for the Berkeley DB database environment 45 are methods of the <a class="link" href="env.html" title="Chapter��5.�� The DB_ENV Handle">DB_ENV</a> 46 handle. The <code class="classname">DB_LOCK</code> object is 47 the handle for a single lock, and has no methods of its own. 48 </p> 49 <div class="sect1" lang="en" xml:lang="en"> 50 <div class="titlepage"> 51 <div> 52 <div> 53 <h2 class="title" style="clear: both"><a id="locklist"></a>Locking Subsystem and Related Methods</h2> 54 </div> 55 </div> 56 </div> 57 <div class="navtable"> 58 <table border="1" width="80%"> 59 <thead> 60 <tr> 61 <th>Locking Subsystem and Related Methods</th> 62 <th>Description</th> 63 </tr> 64 </thead> 65 <tbody> 66 <tr> 67 <td> 68 <a class="xref" href="lockdetect.html" title="DB_ENV->lock_detect()">DB_ENV->lock_detect()</a> 69 </td> 70 <td>Perform deadlock detection</td> 71 </tr> 72 <tr> 73 <td> 74 <a class="xref" href="lockget.html" title="DB_ENV->lock_get()">DB_ENV->lock_get()</a> 75 </td> 76 <td>Acquire a lock</td> 77 </tr> 78 <tr> 79 <td> 80 <a class="xref" href="lockid.html" title="DB_ENV->lock_id()">DB_ENV->lock_id()</a> 81 </td> 82 <td>Acquire a locker ID</td> 83 </tr> 84 <tr> 85 <td> 86 <a class="xref" href="lockid_free.html" title="DB_ENV->lock_id_free()">DB_ENV->lock_id_free()</a> 87 </td> 88 <td>Release a locker ID</td> 89 </tr> 90 <tr> 91 <td> 92 <a class="xref" href="lockput.html" title="DB_ENV->lock_put()">DB_ENV->lock_put()</a> 93 </td> 94 <td>Release a lock</td> 95 </tr> 96 <tr> 97 <td> 98 <a class="xref" href="lockstat.html" title="DB_ENV->lock_stat()">DB_ENV->lock_stat()</a> 99 </td> 100 <td>Return lock subsystem statistics</td> 101 </tr> 102 <tr> 103 <td> 104 <a class="xref" href="lockstat_print.html" title="DB_ENV->lock_stat_print()">DB_ENV->lock_stat_print()</a> 105 </td> 106 <td>Print lock subsystem statistics</td> 107 </tr> 108 <tr> 109 <td> 110 <a class="xref" href="lockvec.html" title="DB_ENV->lock_vec()">DB_ENV->lock_vec()</a> 111 </td> 112 <td>Acquire/release locks</td> 113 </tr> 114 <tr> 115 <td> 116 <a class="xref" href="envcdsgroup_begin.html" title="DB_ENV->cdsgroup_begin()">DB_ENV->cdsgroup_begin()</a> 117 </td> 118 <td>Get a locker ID in Berkeley DB Concurrent Data Store</td> 119 </tr> 120 <tr> 121 <td colspan="2"> 122 <span class="bold"> 123 <strong>Locking Subsystem Configuration</strong> 124 </span> 125 </td> 126 </tr> 127 <tr> 128 <td><a class="xref" href="envset_timeout.html" title="DB_ENV->set_timeout()">DB_ENV->set_timeout()</a>, <a class="xref" href="envget_timeout.html" title="DB_ENV->get_timeout()">DB_ENV->get_timeout()</a></td> 129 <td>Set/get lock and transaction timeout</td> 130 </tr> 131 <tr> 132 <td><a class="xref" href="envset_lk_conflicts.html" title="DB_ENV->set_lk_conflicts()">DB_ENV->set_lk_conflicts()</a>, <a class="xref" href="envget_lk_conflicts.html" title="DB_ENV->get_lk_conflicts()">DB_ENV->get_lk_conflicts()</a></td> 133 <td>Set/get lock conflicts matrix</td> 134 </tr> 135 <tr> 136 <td><a class="xref" href="envset_lk_detect.html" title="DB_ENV->set_lk_detect()">DB_ENV->set_lk_detect()</a>, <a class="xref" href="envget_lk_detect.html" title="DB_ENV->get_lk_detect()">DB_ENV->get_lk_detect()</a></td> 137 <td>Set/get automatic deadlock detection</td> 138 </tr> 139 <tr> 140 <td><a class="xref" href="envset_lk_max_lockers.html" title="DB_ENV->set_lk_max_lockers()">DB_ENV->set_lk_max_lockers()</a>, <a class="xref" href="envget_lk_max_lockers.html" title="DB_ENV->get_lk_max_lockers()">DB_ENV->get_lk_max_lockers()</a></td> 141 <td>Set/get maximum number of lockers</td> 142 </tr> 143 <tr> 144 <td><a class="xref" href="envset_lk_max_locks.html" title="DB_ENV->set_lk_max_locks()">DB_ENV->set_lk_max_locks()</a>, <a class="xref" href="envget_lk_max_locks.html" title="DB_ENV->get_lk_max_locks()">DB_ENV->get_lk_max_locks()</a></td> 145 <td>Set/get maximum number of locks</td> 146 </tr> 147 <tr> 148 <td><a class="xref" href="envset_lk_max_objects.html" title="DB_ENV->set_lk_max_objects()">DB_ENV->set_lk_max_objects()</a>, <a class="xref" href="envget_lk_max_objects.html" title="DB_ENV->get_lk_max_objects()">DB_ENV->get_lk_max_objects()</a></td> 149 <td>Set/get maximum number of lock objects</td> 150 </tr> 151 <tr> 152 <td><a class="xref" href="envset_lk_partitions.html" title="DB_ENV->set_lk_partitions()">DB_ENV->set_lk_partitions()</a>, <a class="xref" href="envget_lk_partitions.html" title="DB_ENV->get_lk_partitions()">DB_ENV->get_lk_partitions()</a></td> 153 <td>Set/get number of lock partitions</td> 154 </tr> 155 </tbody> 156 </table> 157 </div> 158 </div> 159 </div> 160 <div class="navfooter"> 161 <hr /> 162 <table width="100%" summary="Navigation footer"> 163 <tr> 164 <td width="40%" align="left"><a accesskey="p" href="envversion.html">Prev</a>��</td> 165 <td width="20%" align="center">��</td> 166 <td width="40%" align="right">��<a accesskey="n" href="envget_lk_conflicts.html">Next</a></td> 167 </tr> 168 <tr> 169 <td width="40%" align="left" valign="top">db_version��</td> 170 <td width="20%" align="center"> 171 <a accesskey="h" href="index.html">Home</a> 172 </td> 173 <td width="40%" align="right" valign="top">��DB_ENV->get_lk_conflicts()</td> 174 </tr> 175 </table> 176 </div> 177 </body> 178</html> 179