• Home
  • History
  • Annotate
  • Line#
  • Navigate
  • Raw
  • Download
  • only in /asuswrt-rt-n18u-9.0.0.4.380.2695/release/src/router/db-4.8.30/docs/api_reference/CXX/
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>DbEnv::get_timeout()</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="env.html" title="Chapter 5.  The DbEnv Handle" />
11    <link rel="prev" href="envget_thread_count.html" title="DbEnv::get_thread_count()" />
12    <link rel="next" href="envget_tmp_dir.html" title="DbEnv::get_tmp_dir()" />
13  </head>
14  <body>
15    <div class="navheader">
16      <table width="100%" summary="Navigation header">
17        <tr>
18          <th colspan="3" align="center">DbEnv::get_timeout()</th>
19        </tr>
20        <tr>
21          <td width="20%" align="left"><a accesskey="p" href="envget_thread_count.html">Prev</a> </td>
22          <th width="60%" align="center">Chapter 5. 
23                The DbEnv Handle
24        </th>
25          <td width="20%" align="right"> <a accesskey="n" href="envget_tmp_dir.html">Next</a></td>
26        </tr>
27      </table>
28      <hr />
29    </div>
30    <div class="sect1" lang="en" xml:lang="en">
31      <div class="titlepage">
32        <div>
33          <div>
34            <h2 class="title" style="clear: both"><a id="envget_timeout"></a>DbEnv::get_timeout()</h2>
35          </div>
36        </div>
37      </div>
38      <pre class="programlisting">#include &lt;db_cxx.h&gt;
39
40int
41DbEnv::get_timeout(db_timeout_t *timeoutp, u_int32_t flag);</pre>
42      <p>
43         The <code class="methodname">DbEnv::get_timeout()</code> method returns a value, in
44         microseconds, representing either lock or transaction timeouts. These values are set using the
45         <a class="xref" href="envset_timeout.html" title="DbEnv::set_timeout()">DbEnv::set_timeout()</a>
46         method.
47    </p>
48      <p>
49         The <code class="methodname">DbEnv::get_timeout()</code> method may be called at any time during the
50         life of the application.
51    </p>
52      <p>
53         The <code class="methodname">DbEnv::get_timeout()</code> <span>
54            
55            <span>
56                method either returns a non-zero error value or throws an
57                exception that encapsulates a non-zero error value on
58                failure, and returns 0 on success.
59            </span>
60        </span>
61    </p>
62      <div class="sect2" lang="en" xml:lang="en">
63        <div class="titlepage">
64          <div>
65            <div>
66              <h3 class="title"><a id="id1666436"></a>Parameters</h3>
67            </div>
68          </div>
69        </div>
70        <div class="sect3" lang="en" xml:lang="en">
71          <div class="titlepage">
72            <div>
73              <div>
74                <h4 class="title"><a id="id1666282"></a>flag</h4>
75              </div>
76            </div>
77          </div>
78          <p>
79                          The <span class="bold"><strong>flags</strong></span> parameter must be set to
80                          one of the following values:
81                     </p>
82          <div class="itemizedlist">
83            <ul type="disc">
84              <li>
85                <p><a id="get_timeout_DB_SET_LOCK_TIMEOUT"></a>
86                  <code class="literal">DB_SET_LOCK_TIMEOUT</code>
87            </p>
88                <p>
89                 Return the timeout value for locks in this database environment.
90            </p>
91              </li>
92              <li>
93                <p><a id="get_timeout_DB_SET_TXN_TIMEOUT"></a>
94                  <code class="literal">DB_SET_TXN_TIMEOUT</code>
95            </p>
96                <p>
97                 Return the timeout value for transactions in this database
98                 environment.
99            </p>
100              </li>
101            </ul>
102          </div>
103        </div>
104        <div class="sect3" lang="en" xml:lang="en">
105          <div class="titlepage">
106            <div>
107              <div>
108                <h4 class="title"><a id="id1666288"></a>timeoutp</h4>
109              </div>
110            </div>
111          </div>
112          <p>
113                          The <span class="bold"><strong>timeoutp</strong></span> parameter references
114                          memory into which  the timeout value of the specified <span class="bold"><strong>flag</strong></span> parameter is copied.
115                     </p>
116        </div>
117      </div>
118      <div class="sect2" lang="en" xml:lang="en">
119        <div class="titlepage">
120          <div>
121            <div>
122              <h3 class="title"><a id="id1666564"></a>Class</h3>
123            </div>
124          </div>
125        </div>
126        <p>
127                <a class="link" href="env.html" title="Chapter 5.  The DbEnv Handle">DbEnv</a>  
128            </p>
129      </div>
130      <div class="sect2" lang="en" xml:lang="en">
131        <div class="titlepage">
132          <div>
133            <div>
134              <h3 class="title"><a id="id1666437"></a>See Also</h3>
135            </div>
136          </div>
137        </div>
138        <p>
139                     <a class="xref" href="env.html#envlist" title="Database Environments and Related Methods">Database Environments and Related Methods</a>, 
140                     <a class="xref" href="envset_timeout.html" title="DbEnv::set_timeout()">DbEnv::set_timeout()</a>
141                </p>
142      </div>
143    </div>
144    <div class="navfooter">
145      <hr />
146      <table width="100%" summary="Navigation footer">
147        <tr>
148          <td width="40%" align="left"><a accesskey="p" href="envget_thread_count.html">Prev</a> </td>
149          <td width="20%" align="center">
150            <a accesskey="u" href="env.html">Up</a>
151          </td>
152          <td width="40%" align="right"> <a accesskey="n" href="envget_tmp_dir.html">Next</a></td>
153        </tr>
154        <tr>
155          <td width="40%" align="left" valign="top">DbEnv::get_thread_count() </td>
156          <td width="20%" align="center">
157            <a accesskey="h" href="index.html">Home</a>
158          </td>
159          <td width="40%" align="right" valign="top"> DbEnv::get_tmp_dir()</td>
160        </tr>
161      </table>
162    </div>
163  </body>
164</html>
165