Debian Codegraph @

docs/api_reference/CXX/mempput.html

raw symbols SCIP
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>DbMpoolFile::put()</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="memp.html" title="Chapter 9.  The DbMpoolFile Handle" />
11 <link rel="prev" href="mempfopen.html" title="DbMpoolFile::open()" />
12 <link rel="next" href="mempfsync.html" title="DbMpoolFile::sync()" />
13 </head>
14 <body>
15 <div xmlns="" class="navheader">
16 <div class="libver">
17 <p>Library Version 11.2.5.3</p>
18 </div>
19 <table width="100%" summary="Navigation header">
20 <tr>
21 <th colspan="3" align="center">DbMpoolFile::put()</th>
22 </tr>
23 <tr>
24 <td width="20%" align="left"><a accesskey="p" href="mempfopen.html">Prev</a> </td>
25 <th width="60%" align="center">Chapter 9. 
26 The DbMpoolFile Handle
27 </th>
28 <td width="20%" align="right"> <a accesskey="n" href="mempfsync.html">Next</a></td>
29 </tr>
30 </table>
31 <hr />
32 </div>
33 <div class="sect1" lang="en" xml:lang="en">
34 <div class="titlepage">
35 <div>
36 <div>
37 <h2 class="title" style="clear: both"><a id="mempput"></a>DbMpoolFile::put()</h2>
38 </div>
39 </div>
40 </div>
41 <pre class="programlisting">#include &lt;db_cxx.h&gt;
42
43 int
44 DbMpoolFile::put(void *pgaddr, DB_CACHE_PRIORITY priority,
45 u_int32_t flags);</pre>
46 <p>
47 The <code class="methodname">DbMpoolFile::put()</code> method returns a reference to a page in the
48 cache, setting the priority of the page as specified by the <span class="bold"><strong>priority</strong></span> parameter.
49 </p>
50 <p>
51 The <code class="methodname">DbMpoolFile::put()</code> <span>
52
53 <span>
54 method either returns a non-zero error value or throws an
55 exception that encapsulates a non-zero error value on
56 failure, and returns 0 on success.
57 </span>
58 </span>
59 </p>
60 <div class="sect2" lang="en" xml:lang="en">
61 <div class="titlepage">
62 <div>
63 <div>
64 <h3 class="title"><a id="idp8945448"></a>Parameters</h3>
65 </div>
66 </div>
67 </div>
68 <div class="sect3" lang="en" xml:lang="en">
69 <div class="titlepage">
70 <div>
71 <div>
72 <h4 class="title"><a id="idp8944968"></a>pgaddr</h4>
73 </div>
74 </div>
75 </div>
76 <p>
77 The <span class="bold"><strong>pgaddr</strong></span> parameter is the address
78 of the page to be returned to the cache. The <span class="bold"><strong>pgaddr</strong></span> parameter must be a value previously
79 returned by the
80 <a class="xref" href="mempfget.html" title="DbMpoolFile::get()">DbMpoolFile::get()</a> method.
81 </p>
82 </div>
83 <div class="sect3" lang="en" xml:lang="en">
84 <div class="titlepage">
85 <div>
86 <div>
87 <h4 class="title"><a id="idp8937032"></a>priority</h4>
88 </div>
89 </div>
90 </div>
91 <p>
92 Set the page's <span class="bold"><strong>priority</strong></span> as follows:
93 </p>
94 <div class="itemizedlist">
95 <ul type="disc">
96 <li>
97 <p><a id="fput_DB_PRIORITY_UNCHANGED"></a>
98 <code class="literal">DB_PRIORITY_UNCHANGED</code>
99 </p>
100 <p>
101 The priority is unchanged.
102 </p>
103 </li>
104 <li>
105 <p>
106 <code class="literal">DB_PRIORITY_VERY_LOW</code>
107 </p>
108 <p>
109 The lowest priority: pages are the most likely to be discarded.
110 </p>
111 </li>
112 <li>
113 <p>
114 <code class="literal">DB_PRIORITY_LOW</code>
115 </p>
116 <p>
117 The next lowest priority.
118 </p>
119 </li>
120 <li>
121 <p>
122 <code class="literal">DB_PRIORITY_DEFAULT</code>
123 </p>
124 <p>
125 The default priority.
126 </p>
127 </li>
128 <li>
129 <p>
130 <code class="literal">DB_PRIORITY_HIGH</code>
131 </p>
132 <p>
133 The next highest priority.
134 </p>
135 </li>
136 <li>
137 <p>
138 <code class="literal">DB_PRIORITY_VERY_HIGH</code>
139 </p>
140 <p>
141 The highest priority: pages are the least likely to be discarded.
142 </p>
143 </li>
144 </ul>
145 </div>
146 </div>
147 <div class="sect3" lang="en" xml:lang="en">
148 <div class="titlepage">
149 <div>
150 <div>
151 <h4 class="title"><a id="idp8958024"></a>flags</h4>
152 </div>
153 </div>
154 </div>
155 <p>
156 The <span class="bold"><strong>flags</strong></span> parameter is currently
157 unused, and must be set to 0.
158 </p>
159 </div>
160 </div>
161 <div class="sect2" lang="en" xml:lang="en">
162 <div class="titlepage">
163 <div>
164 <div>
165 <h3 class="title"><a id="idp8959352"></a>Errors</h3>
166 </div>
167 </div>
168 </div>
169 <p>
170 The <code class="methodname">DbMpoolFile::put()</code> <span>
171
172 <span>
173 method may fail and throw a <a class="link" href="dbexception.html" title="Chapter 6. The DbException Class">DbException</a>
174 exception, encapsulating one of the following non-zero errors, or return one
175 of the following non-zero errors:
176 </span>
177 </span>
178 </p>
179 <div class="sect3" lang="en" xml:lang="en">
180 <div class="titlepage">
181 <div>
182 <div>
183 <h4 class="title"><a id="idp8956296"></a>EINVAL</h4>
184 </div>
185 </div>
186 </div>
187 <p>
188 An invalid flag value or parameter was specified.
189 </p>
190 </div>
191 </div>
192 <div class="sect2" lang="en" xml:lang="en">
193 <div class="titlepage">
194 <div>
195 <div>
196 <h3 class="title"><a id="idp8964032"></a>Class</h3>
197 </div>
198 </div>
199 </div>
200 <p>
201 <a class="link" href="env.html" title="Chapter 5.  The DbEnv Handle">DbEnv</a>, <a class="link" href="memp.html" title="Chapter 9.  The DbMpoolFile Handle">DbMpoolFile</a>
202 </p>
203 </div>
204 <div class="sect2" lang="en" xml:lang="en">
205 <div class="titlepage">
206 <div>
207 <div>
208 <h3 class="title"><a id="idp8949448"></a>See Also</h3>
209 </div>
210 </div>
211 </div>
212 <p>
213 <a class="xref" href="memp.html#memplist" title="Memory Pools and Related Methods">Memory Pools and Related Methods</a>
214 </p>
215 </div>
216 </div>
217 <div class="navfooter">
218 <hr />
219 <table width="100%" summary="Navigation footer">
220 <tr>
221 <td width="40%" align="left"><a accesskey="p" href="mempfopen.html">Prev</a> </td>
222 <td width="20%" align="center">
223 <a accesskey="u" href="memp.html">Up</a>
224 </td>
225 <td width="40%" align="right"> <a accesskey="n" href="mempfsync.html">Next</a></td>
226 </tr>
227 <tr>
228 <td width="40%" align="left" valign="top">DbMpoolFile::open() </td>
229 <td width="20%" align="center">
230 <a accesskey="h" href="index.html">Home</a>
231 </td>
232 <td width="40%" align="right" valign="top"> DbMpoolFile::sync()</td>
233 </tr>
234 </table>
235 </div>
236 </body>
237 </html>