JunkBox_Lib++ (for Windows)
1.10.1
Loading...
Searching...
No Matches
bdb_tool.h
Go to the documentation of this file.
1
#ifndef __JBXL_BERKELEY_DB4_H__
2
#define __JBXL_BERKELEY_DB4_H__
3
17
#include "
tlist.h
"
18
19
//
20
#ifdef DISABLE_BERKELEYDB
21
#ifdef ENABLE_BERKELEYDB
22
#undef ENABLE_BERKELEYDB
23
#endif
24
#endif
25
26
//
27
#ifdef ENABLE_BERKELEYDB
28
#ifndef HAVE_DB_H
29
#ifndef DISABLE_BERKELEYDB
30
#define DISABLE_BERKELEYDB
31
#endif
32
#undef ENABLE_BERKELEYDB
33
#endif
34
#endif
35
36
37
//
38
#ifdef ENABLE_BERKELEYDB
39
40
41
#if ! defined (HAVE_DB_H) && ! defined (HAVE_LIBDB_4_2)
42
#error fdb.h needs Berkley
43
#endif
44
45
46
#define DB_DBM_HSEARCH 1
47
#include <db.h>
48
49
#include <fcntl.h>
50
51
53
//
54
DB* open_fdb(
char
* fname,
unsigned
int
mode);
55
void
close_fdb(DB** dp);
56
57
#define flush_fdb(d) (d)->sync((d), 0)
58
59
int
set_fdb_data(DB* dp,
Buffer
id
,
Buffer
dbdata);
60
int
del_fdb_data(DB* dp,
Buffer
id
);
61
Buffer
get_fdb_data(DB* dp,
Buffer
id
);
62
63
65
// for file
66
int
check_fdb_file(
char
* fname);
67
int
set_fdb_data_file(
char
* fname,
Buffer
id
,
Buffer
dbdata);
68
int
del_fdb_data_file(
char
* fname,
Buffer
id
);
69
Buffer
get_fdb_data_file(
char
* fname,
Buffer
id
);
70
71
73
//
74
tList
* get_all_fdb_data(DB* dp);
75
tList
* get_all_fdb_data_file(
char
* fname);
76
77
78
#endif
// ENABLE_BERKELEYDB
79
80
#endif
// __JBXL_BERKELEY_DB4_H__
81
Buffer
Definition
buffer.h:35
tList
tlist.h
Tiny List 構造ライブラリヘッダ
ExtendLib
xLib
bdb_tool.h
Generated on Sat Oct 12 2024 19:42:08 for JunkBox_Lib++ (for Windows) by
1.11.0