xapian-core  1.4.19
constants.h
Go to the documentation of this file.
1 
4 /* Copyright (C) 2012,2013,2014,2015,2016 Olly Betts
5  *
6  * This program is free software; you can redistribute it and/or
7  * modify it under the terms of the GNU General Public License as
8  * published by the Free Software Foundation; either version 2 of the
9  * License, or (at your option) any later version.
10  *
11  * This program is distributed in the hope that it will be useful,
12  * but WITHOUT ANY WARRANTY; without even the implied warranty of
13  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14  * GNU General Public License for more details.
15  *
16  * You should have received a copy of the GNU General Public License
17  * along with this program; if not, write to the Free Software
18  * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301
19  * USA
20  */
21 
22 #ifndef XAPIAN_INCLUDED_CONSTANTS_H
23 #define XAPIAN_INCLUDED_CONSTANTS_H
24 
25 #if !defined XAPIAN_IN_XAPIAN_H && !defined XAPIAN_LIB_BUILD
26 # error Never use <xapian/constants.h> directly; include <xapian.h> instead.
27 #endif
28 
29 namespace Xapian {
30 
35 const int DB_CREATE_OR_OPEN = 0x00;
36 
38 const int DB_CREATE_OR_OVERWRITE = 0x01;
39 
44 const int DB_CREATE = 0x02;
45 
50 const int DB_OPEN = 0x03;
51 
52 #ifdef XAPIAN_LIB_BUILD
53 
54 const int DB_ACTION_MASK_ = 0x03;
55 #endif
56 
66 const int DB_NO_SYNC = 0x04;
67 
83 const int DB_FULL_SYNC = 0x08;
84 
103 const int DB_DANGEROUS = 0x10;
104 
136 const int DB_NO_TERMLIST = 0x20;
137 
145 const int DB_RETRY_LOCK = 0x40;
146 
158 const int DB_BACKEND_GLASS = 0x100;
159 
170 const int DB_BACKEND_CHERT = 0x200;
171 
179 const int DB_BACKEND_STUB = 0x300;
180 
195 const int DB_BACKEND_INMEMORY = 0x400;
196 
197 #ifdef XAPIAN_LIB_BUILD
198 
199 const int DB_BACKEND_MASK_ = 0x700;
200 
202 const int DB_READONLY_ = -1;
203 #endif
204 
205 
210 const int DBCHECK_SHORT_TREE = 1;
211 
216 const int DBCHECK_FULL_TREE = 2;
217 
222 const int DBCHECK_SHOW_FREELIST = 4;
223 
228 const int DBCHECK_SHOW_STATS = 8;
229 
243 const int DBCHECK_FIX = 16;
244 
245 
256 const int DBCOMPACT_NO_RENUMBER = 4;
257 
262 const int DBCOMPACT_MULTIPASS = 8;
263 
268 const int DBCOMPACT_SINGLE_FILE = 16;
269 
280 const int DOC_ASSUME_VALID = 1;
281 
282 }
283 
284 #endif /* XAPIAN_INCLUDED_CONSTANTS_H */
const int DB_BACKEND_INMEMORY
Use the "in memory" backend.
Definition: constants.h:195
The Xapian namespace contains public interfaces for the Xapian library.
Definition: compactor.cc:80
const int DB_CREATE
Create a new database.
Definition: constants.h:44
const int DB_FULL_SYNC
Try to ensure changes are really written to disk.
Definition: constants.h:83
const int DB_CREATE_OR_OPEN
Create database if it doesn&#39;t already exist.
Definition: constants.h:35
const int DBCOMPACT_NO_RENUMBER
Use the same document ids in the output as in the input(s).
Definition: constants.h:256
const int DOC_ASSUME_VALID
Assume document id is valid.
Definition: constants.h:280
const int DBCHECK_SHOW_FREELIST
Show the bitmap for the B-tree.
Definition: constants.h:222
const int DB_BACKEND_GLASS
Use the glass backend.
Definition: constants.h:158
const int DBCHECK_FULL_TREE
Show a full display of the B-tree contents.
Definition: constants.h:216
const int DB_OPEN
Open an existing database.
Definition: constants.h:50
const int DB_DANGEROUS
Update the database in-place.
Definition: constants.h:103
const int DBCHECK_FIX
Fix problems.
Definition: constants.h:243
const int DB_NO_SYNC
Don&#39;t attempt to ensure changes have hit disk.
Definition: constants.h:66
const int DB_BACKEND_STUB
Open a stub database file.
Definition: constants.h:179
const int DB_NO_TERMLIST
When creating a database, don&#39;t create a termlist table.
Definition: constants.h:136
const int DBCOMPACT_MULTIPASS
If merging more than 3 databases, merge the postlists in multiple passes.
Definition: constants.h:262
const int DB_RETRY_LOCK
If the database is already locked, retry the lock.
Definition: constants.h:145
const int DB_CREATE_OR_OVERWRITE
Create database if it doesn&#39;t already exist, or overwrite if it does.
Definition: constants.h:38
const int DBCOMPACT_SINGLE_FILE
Produce a single-file database.
Definition: constants.h:268
const int DB_BACKEND_CHERT
Use the chert backend.
Definition: constants.h:170
const int DBCHECK_SHORT_TREE
Show a short-format display of the B-tree contents.
Definition: constants.h:210
const int DBCHECK_SHOW_STATS
Show statistics for the B-tree.
Definition: constants.h:228