1 #ifndef _PROTO_BACK_LDBM
2 #define _PROTO_BACK_LDBM
8 void attr_masks( struct ldbminfo *li, char *type, int *indexmask,
10 void attr_index_config( struct ldbminfo *li, char *fname, int lineno,
11 int argc, char **argv, int init );
17 void cache_set_state( struct cache *cache, Entry *e, int state );
18 void cache_return_entry( struct cache *cache, Entry *e );
19 int cache_add_entry_lock( struct cache *cache, Entry *e, int state );
20 Entry * cache_find_entry_dn( struct cache *cache, char *dn );
21 Entry * cache_find_entry_id( struct cache *cache, ID id );
22 int cache_delete_entry( struct cache *cache, Entry *e );
28 struct dbcache * ldbm_cache_open( Backend *be, char *name, char *suffix,
30 void ldbm_cache_close( Backend *be, struct dbcache *db );
31 void ldbm_cache_flush_all( Backend *be );
32 Datum ldbm_cache_fetch( struct dbcache *db, Datum key );
33 int ldbm_cache_store( struct dbcache *db, Datum key, Datum data, int flags );
34 int ldbm_cache_delete( struct dbcache *db, Datum key );
40 int dn2id_add( Backend *be, char *dn, ID id );
41 ID dn2id( Backend *be, char *dn );
42 int dn2id_delete( Backend *be, char *dn );
43 Entry * dn2entry( Backend *be, char *dn, char **matched );
49 IDList * filter_candidates( Backend *be, Filter *f );
55 int id2children_add( Backend *be, Entry *p, Entry *e );
56 int has_children( Backend *be, Entry *p );
62 int id2entry_add( Backend *be, Entry *e );
63 int id2entry_delete( Backend *be, Entry *e );
64 Entry * id2entry( Backend *be, ID id );
70 IDList * idl_alloc( int nids );
71 IDList * idl_allids( Backend *be );
72 void idl_free( IDList *idl );
73 IDList * idl_fetch( Backend *be, struct dbcache *db, Datum key );
74 int idl_insert_key( Backend *be, struct dbcache *db, Datum key, ID id );
75 int idl_insert( IDList **idl, ID id, int maxids );
76 IDList * idl_intersection( Backend *be, IDList *a, IDList *b );
77 IDList * idl_union( Backend *be, IDList *a, IDList *b );
78 IDList * idl_notin( Backend *be, IDList *a, IDList *b );
79 ID idl_firstid( IDList *idl );
80 ID idl_nextid( IDList *idl, ID id );
86 int index_add_entry( Backend *be, Entry *e );
87 int index_add_mods( Backend *be, LDAPMod *mods, ID id );
88 IDList * index_read( Backend *be, char *type, int indextype, char *val );
89 int index_add_values( Backend *be, char *type, struct berval **vals, ID id );
96 /* krbv4_ldap_auth( Backend *be, struct berval *cred, AUTH_DAT *ad ); */
103 ID next_id( Backend *be );
104 void next_id_return( Backend *be, ID id );
105 ID next_id_get( Backend *be );