]> git.sur5r.net Git - openldap/blob - servers/slapd/back-ldbm/proto-back-ldbm.h
Move LDBM-backend specific fields of Entry struct into a private struct.
[openldap] / servers / slapd / back-ldbm / proto-back-ldbm.h
1 #ifndef _PROTO_BACK_LDBM
2 #define _PROTO_BACK_LDBM
3
4 #include <ldap_cdefs.h>
5
6 #include "external.h"
7
8 LDAP_BEGIN_DECL
9
10 /*
11  * alias.c
12  */
13 Entry *derefAlias_r LDAP_P((
14         Backend     *be,
15         Connection      *conn,
16         Operation       *op,
17         Entry       *e ));
18 char *derefDN LDAP_P((
19         Backend     *be,
20         Connection  *conn,
21         Operation   *op,
22         char        *dn ));
23
24 /*
25  * attr.c
26  */
27
28 void attr_masks LDAP_P(( struct ldbminfo *li, char *type, int *indexmask,
29  int *syntaxmask ));
30 void attr_index_config LDAP_P(( struct ldbminfo *li, char *fname, int lineno,
31  int argc, char **argv, int init ));
32
33 /*
34  * cache.c
35  */
36
37 void cache_set_state LDAP_P(( struct cache *cache, Entry *e, int state ));
38 void cache_return_entry_r LDAP_P(( struct cache *cache, Entry *e ));
39 void cache_return_entry_w LDAP_P(( struct cache *cache, Entry *e ));
40 int cache_add_entry_rw LDAP_P(( struct cache *cache, Entry *e,
41         int state, int rw ));
42 int cache_update_entry LDAP_P(( struct cache *cache, Entry *e ));
43 ID cache_find_entry_dn2id LDAP_P(( Backend *be, struct cache *cache, char *dn ));
44 Entry * cache_find_entry_id LDAP_P(( struct cache *cache, ID id, int rw ));
45 int cache_delete_entry LDAP_P(( struct cache *cache, Entry *e ));
46
47 /*
48  * dbcache.c
49  */
50
51 struct dbcache * ldbm_cache_open LDAP_P(( Backend *be, char *name, char *suffix,
52  int flags ));
53 void ldbm_cache_close LDAP_P(( Backend *be, struct dbcache *db ));
54 void ldbm_cache_really_close LDAP_P(( Backend *be, struct dbcache *db ));
55 void ldbm_cache_flush_all LDAP_P(( Backend *be ));
56 Datum ldbm_cache_fetch LDAP_P(( struct dbcache *db, Datum key ));
57 int ldbm_cache_store LDAP_P(( struct dbcache *db, Datum key, Datum data, int flags ));
58 int ldbm_cache_delete LDAP_P(( struct dbcache *db, Datum key ));
59
60 /*
61  * dn2id.c
62  */
63
64 int dn2id_add LDAP_P(( Backend *be, char *dn, ID id ));
65 ID dn2id LDAP_P(( Backend *be, char *dn ));
66 int dn2id_delete LDAP_P(( Backend *be, char *dn ));
67 Entry * dn2entry_r LDAP_P(( Backend *be, char *dn, char **matched ));
68 Entry * dn2entry_w LDAP_P(( Backend *be, char *dn, char **matched ));
69
70 /*
71  * filterindex.c
72  */
73
74 ID_BLOCK * filter_candidates LDAP_P(( Backend *be, Filter *f ));
75
76 /*
77  * id2children.c
78  */
79
80 int id2children_add LDAP_P(( Backend *be, Entry *p, Entry *e ));
81 int id2children_remove LDAP_P(( Backend *be, Entry *p, Entry *e ));
82 int has_children LDAP_P(( Backend *be, Entry *p ));
83
84 /*
85  * id2entry.c
86  */
87
88 int id2entry_add LDAP_P(( Backend *be, Entry *e ));
89 int id2entry_delete LDAP_P(( Backend *be, Entry *e ));
90 Entry * id2entry_rw LDAP_P(( Backend *be, ID id, int rw )); 
91 Entry * id2entry_r LDAP_P(( Backend *be, ID id ));
92 Entry * id2entry_w LDAP_P(( Backend *be, ID id ));
93
94 /*
95  * idl.c
96  */
97
98 ID_BLOCK * idl_alloc LDAP_P(( int nids ));
99 ID_BLOCK * idl_allids LDAP_P(( Backend *be ));
100 void idl_free LDAP_P(( ID_BLOCK *idl ));
101 ID_BLOCK * idl_fetch LDAP_P(( Backend *be, struct dbcache *db, Datum key ));
102 int idl_insert_key LDAP_P(( Backend *be, struct dbcache *db, Datum key, ID id ));
103 int idl_insert LDAP_P(( ID_BLOCK **idl, ID id, int maxids ));
104 int idl_delete_key LDAP_P(( Backend *be, struct dbcache *db, Datum key, ID id ));
105 ID_BLOCK * idl_intersection LDAP_P(( Backend *be, ID_BLOCK *a, ID_BLOCK *b ));
106 ID_BLOCK * idl_union LDAP_P(( Backend *be, ID_BLOCK *a, ID_BLOCK *b ));
107 ID_BLOCK * idl_notin LDAP_P(( Backend *be, ID_BLOCK *a, ID_BLOCK *b ));
108 ID idl_firstid LDAP_P(( ID_BLOCK *idl ));
109 ID idl_nextid LDAP_P(( ID_BLOCK *idl, ID id ));
110
111 /*
112  * index.c
113  */
114
115 int index_add_entry LDAP_P(( Backend *be, Entry *e ));
116 int index_add_mods LDAP_P(( Backend *be, LDAPModList *ml, ID id ));
117 ID_BLOCK * index_read LDAP_P(( Backend *be, char *type, int indextype, char *val ));
118 int index_add_values LDAP_P(( Backend *be, char *type, struct berval **vals, ID  id ));
119
120 /*
121  * kerberos.c
122  */
123
124 #ifdef HAVE_KERBEROS
125 /* krbv4_ldap_auth LDAP_P(( Backend *be, struct berval *cred, AUTH_DAT *ad )); */
126 #endif
127
128 /*
129  * nextid.c
130  */
131
132 ID next_id LDAP_P(( Backend *be ));
133 void next_id_return LDAP_P(( Backend *be, ID id ));
134 ID next_id_get LDAP_P(( Backend *be ));
135 int next_id_save LDAP_P(( Backend *be ));
136
137 LDAP_END_DECL
138 #endif