]> git.sur5r.net Git - openldap/blob - servers/slapd/back-ldbm/proto-back-ldbm.h
b9fd37bbdc582c04e4610399558b9c2f986a5b42
[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 LDAP_BEGIN_DECL
7
8 /*
9  * alias.c
10  */
11 #ifdef SLAPD_ALIAS_DEREF
12 Entry *derefAlias_r LDAP_P((
13         Backend     *be,
14         Connection      *conn,
15         Operation       *op,
16         Entry       *e ));
17 char *derefDN LDAP_P((
18         Backend     *be,
19         Connection  *conn,
20         Operation   *op,
21         char        *dn ));
22 #endif
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_lock LDAP_P(( struct cache *cache, Entry *e, int state ));
41 ID cache_find_entry_dn2id LDAP_P(( Backend *be, struct cache *cache, char *dn ));
42 Entry * cache_find_entry_id LDAP_P(( struct cache *cache, ID id, int rw ));
43 int cache_delete_entry LDAP_P(( struct cache *cache, Entry *e ));
44
45 /*
46  * dbcache.c
47  */
48
49 struct dbcache * ldbm_cache_open LDAP_P(( Backend *be, char *name, char *suffix,
50  int flags ));
51 void ldbm_cache_close LDAP_P(( Backend *be, struct dbcache *db ));
52 void ldbm_cache_really_close LDAP_P(( Backend *be, struct dbcache *db ));
53 void ldbm_cache_flush_all LDAP_P(( Backend *be ));
54 Datum ldbm_cache_fetch LDAP_P(( struct dbcache *db, Datum key ));
55 int ldbm_cache_store LDAP_P(( struct dbcache *db, Datum key, Datum data, int flags ));
56 int ldbm_cache_delete LDAP_P(( struct dbcache *db, Datum key ));
57
58 /*
59  * dn2id.c
60  */
61
62 int dn2id_add LDAP_P(( Backend *be, char *dn, ID id ));
63 ID dn2id LDAP_P(( Backend *be, char *dn ));
64 int dn2id_delete LDAP_P(( Backend *be, char *dn ));
65 Entry * dn2entry_r LDAP_P(( Backend *be, char *dn, char **matched ));
66 Entry * dn2entry_w LDAP_P(( Backend *be, char *dn, char **matched ));
67
68 /*
69  * filterindex.c
70  */
71
72 IDList * filter_candidates LDAP_P(( Backend *be, Filter *f ));
73
74 /*
75  * id2children.c
76  */
77
78 int id2children_add LDAP_P(( Backend *be, Entry *p, Entry *e ));
79 int id2children_remove LDAP_P(( Backend *be, Entry *p, Entry *e ));
80 int has_children LDAP_P(( Backend *be, Entry *p ));
81
82 /*
83  * id2entry.c
84  */
85
86 int id2entry_add LDAP_P(( Backend *be, Entry *e ));
87 int id2entry_delete LDAP_P(( Backend *be, Entry *e ));
88 Entry * id2entry LDAP_P(( Backend *be, ID id, int rw )); 
89 Entry * id2entry_r LDAP_P(( Backend *be, ID id ));
90 Entry * id2entry_w LDAP_P(( Backend *be, ID id ));
91
92 /*
93  * idl.c
94  */
95
96 IDList * idl_alloc LDAP_P(( int nids ));
97 IDList * idl_allids LDAP_P(( Backend *be ));
98 void idl_free LDAP_P(( IDList *idl ));
99 IDList * idl_fetch LDAP_P(( Backend *be, struct dbcache *db, Datum key ));
100 int idl_insert_key LDAP_P(( Backend *be, struct dbcache *db, Datum key, ID id ));
101 int idl_insert LDAP_P(( IDList **idl, ID id, int maxids ));
102 int idl_delete_key LDAP_P(( Backend *be, struct dbcache *db, Datum key, ID id ));
103 IDList * idl_intersection LDAP_P(( Backend *be, IDList *a, IDList *b ));
104 IDList * idl_union LDAP_P(( Backend *be, IDList *a, IDList *b ));
105 IDList * idl_notin LDAP_P(( Backend *be, IDList *a, IDList *b ));
106 ID idl_firstid LDAP_P(( IDList *idl ));
107 ID idl_nextid LDAP_P(( IDList *idl, ID id ));
108
109 /*
110  * index.c
111  */
112
113 int index_add_entry LDAP_P(( Backend *be, Entry *e ));
114 int index_add_mods LDAP_P(( Backend *be, LDAPMod *mods, ID id ));
115 IDList * index_read LDAP_P(( Backend *be, char *type, int indextype, char *val ));
116 int index_add_values LDAP_P(( Backend *be, char *type, struct berval **vals, ID  id ));
117
118 /*
119  * kerberos.c
120  */
121
122 #ifdef HAVE_KERBEROS
123 /* krbv4_ldap_auth LDAP_P(( Backend *be, struct berval *cred, AUTH_DAT *ad )); */
124 #endif
125
126 /*
127  * nextid.c
128  */
129
130 ID next_id LDAP_P(( Backend *be ));
131 void next_id_return LDAP_P(( Backend *be, ID id ));
132 ID next_id_get LDAP_P(( Backend *be ));
133 int next_id_save LDAP_P(( Backend *be ));
134
135 LDAP_END_DECL
136 #endif