]> git.sur5r.net Git - openldap/blob - servers/slapd/back-monitor/proto-back-monitor.h
some overlay (rwm?) might set those values
[openldap] / servers / slapd / back-monitor / proto-back-monitor.h
1 /* $OpenLDAP$ */
2 /* This work is part of OpenLDAP Software <http://www.openldap.org/>.
3  *
4  * Copyright 2001-2006 The OpenLDAP Foundation.
5  * Portions Copyright 2001-2003 Pierangelo Masarati.
6  * All rights reserved.
7  *
8  * Redistribution and use in source and binary forms, with or without
9  * modification, are permitted only as authorized by the OpenLDAP
10  * Public License.
11  *
12  * A copy of this license is available in file LICENSE in the
13  * top-level directory of the distribution or, alternatively, at
14  * <http://www.OpenLDAP.org/license.html>.
15  */
16 /* ACKNOWLEDGEMENTS:
17  * This work was initially developed by Pierangelo Masarati for inclusion
18  * in OpenLDAP Software.
19  */
20
21 #ifndef _PROTO_BACK_MONITOR
22 #define _PROTO_BACK_MONITOR
23
24 #include <ldap_cdefs.h>
25
26 LDAP_BEGIN_DECL
27
28 /*
29  * backends
30  */
31 int
32 monitor_subsys_backend_init LDAP_P((
33         BackendDB               *be,
34         monitor_subsys_t        *ms ));
35
36 /*
37  * cache
38  */
39 extern int
40 monitor_cache_cmp LDAP_P((
41         const void              *c1,
42         const void              *c2 ));
43 extern int
44 monitor_cache_dup LDAP_P((
45         void                    *c1,
46         void                    *c2 ));
47 extern int
48 monitor_cache_add LDAP_P((
49         monitor_info_t          *mi,
50         Entry                   *e ));
51 extern int
52 monitor_cache_get LDAP_P((
53         monitor_info_t          *mi,
54         struct berval           *ndn,
55         Entry                   **ep ));
56 extern int
57 monitor_cache_remove LDAP_P((
58         monitor_info_t          *mi,
59         struct berval           *ndn,
60         Entry                   **ep ));
61 extern int
62 monitor_cache_dn2entry LDAP_P((
63         Operation               *op,
64         SlapReply               *rs,
65         struct berval           *ndn,
66         Entry                   **ep,
67         Entry                   **matched ));
68 extern int
69 monitor_cache_lock LDAP_P((
70         Entry                   *e ));
71 extern int
72 monitor_cache_release LDAP_P((
73         monitor_info_t          *mi,
74         Entry                   *e ));
75
76 extern int
77 monitor_cache_destroy LDAP_P((
78         monitor_info_t          *mi ));
79
80 /*
81  * connections
82  */
83 extern int
84 monitor_subsys_conn_init LDAP_P((
85         BackendDB               *be,
86         monitor_subsys_t        *ms ));
87
88 /*
89  * databases 
90  */
91 extern int
92 monitor_subsys_database_init LDAP_P((
93         BackendDB               *be,
94         monitor_subsys_t        *ms ));
95
96 /*
97  * entry
98  */
99 extern int
100 monitor_entry_update LDAP_P((
101         Operation               *op,
102         SlapReply               *rs,
103         Entry                   *e ));
104 extern int
105 monitor_entry_create LDAP_P((
106         Operation               *op,
107         SlapReply               *rs,
108         struct berval           *ndn,
109         Entry                   *e_parent,
110         Entry                   **ep ));
111 extern int
112 monitor_entry_modify LDAP_P((
113         Operation               *op,
114         SlapReply               *rs,
115         Entry                   *e ));
116 extern int
117 monitor_entry_test_flags LDAP_P((
118         monitor_entry_t         *mp,
119         int                     cond ));
120 extern monitor_entry_t *
121 monitor_entrypriv_create LDAP_P((
122         void ));
123
124 extern Entry *
125 monitor_entry_stub LDAP_P((
126         struct berval   *pdn,
127         struct berval   *pndn,
128         struct berval   *rdn,
129         ObjectClass             *oc,
130         monitor_info_t  *mi,
131         struct berval   *create,
132         struct berval   *modify));
133
134 /*
135  * init
136  */
137 extern int
138 monitor_back_register_subsys LDAP_P((
139         monitor_subsys_t        *ms ));
140 extern monitor_subsys_t *
141 monitor_back_get_subsys LDAP_P((
142         const char              *name ));
143 extern monitor_subsys_t *
144 monitor_back_get_subsys_by_dn LDAP_P((
145         struct berval           *ndn,
146         int                     sub ));
147 extern int
148 monitor_back_is_configured LDAP_P(( void ));
149 extern int
150 monitor_back_register_entry LDAP_P((
151         Entry                   *e,
152         monitor_callback_t      *cb ));
153 extern int
154 monitor_back_register_entry_parent LDAP_P((
155         Entry                   *e,
156         monitor_callback_t      *cb,
157         struct berval           *base,
158         int                     scope,
159         struct berval           *filter ));
160 extern int
161 monitor_filter2ndn LDAP_P((
162         struct berval           *base,
163         int                     scope,
164         struct berval           *filter,
165         struct berval           *ndn ));
166 extern int
167 monitor_back_register_entry_attrs LDAP_P((
168         struct berval           *ndn,
169         Attribute               *a,
170         monitor_callback_t      *cb,
171         struct berval           *base,
172         int                     scope,
173         struct berval           *filter ));
174 extern int
175 monitor_back_register_entry_callback LDAP_P((
176         struct berval           *ndn,
177         monitor_callback_t      *cb,
178         struct berval           *base,
179         int                     scope,
180         struct berval           *filter ));
181 extern int
182 monitor_back_unregister_entry LDAP_P((
183         Entry                   *e ));
184 extern int
185 monitor_back_unregister_entry_attrs LDAP_P((
186         struct berval           *ndn,
187         Attribute               *a,
188         monitor_callback_t      *cb,
189         struct berval           *base,
190         int                     scope,
191         struct berval           *filter ));
192 extern int
193 monitor_back_unregister_entry_callback LDAP_P((
194         struct berval           *ndn,
195         monitor_callback_t      *cb,
196         struct berval           *base,
197         int                     scope,
198         struct berval           *filter ));
199
200 /*
201  * listener
202  */
203 extern int
204 monitor_subsys_listener_init LDAP_P((
205         BackendDB               *be,
206         monitor_subsys_t        *ms ));
207
208 /*
209  * log
210  */
211 extern int
212 monitor_subsys_log_init LDAP_P((
213         BackendDB               *be,
214         monitor_subsys_t        *ms ));
215
216 /*
217  * operations
218  */
219 extern int
220 monitor_subsys_ops_init LDAP_P((
221         BackendDB               *be,
222         monitor_subsys_t        *ms ));
223
224 /*
225  * overlay
226  */
227 extern int
228 monitor_subsys_overlay_init LDAP_P((
229         BackendDB               *be,
230         monitor_subsys_t        *ms ));
231
232 /*
233  * sent
234  */
235 extern int
236 monitor_subsys_sent_init LDAP_P((
237         BackendDB               *be,
238         monitor_subsys_t        *ms ));
239
240 /*
241  * threads
242  */
243 extern int
244 monitor_subsys_thread_init LDAP_P((
245         BackendDB               *be,
246         monitor_subsys_t        *ms ));
247
248 /*
249  * time
250  */
251 extern int monitor_subsys_time_init LDAP_P((
252         BackendDB               *be,
253         monitor_subsys_t        *ms ));
254
255 /*
256  * waiters
257  */
258 extern int
259 monitor_subsys_rww_init LDAP_P((
260         BackendDB               *be,
261         monitor_subsys_t        *ms ));
262
263 /*
264  * former external.h
265  */
266
267 extern BI_init                  monitor_back_initialize;
268
269 extern BI_db_init               monitor_back_db_init;
270 extern BI_db_open               monitor_back_db_open;
271 extern BI_config                monitor_back_config;
272 extern BI_db_destroy            monitor_back_db_destroy;
273 extern BI_db_config             monitor_back_db_config;
274
275 extern BI_op_search             monitor_back_search;
276 extern BI_op_compare            monitor_back_compare;
277 extern BI_op_modify             monitor_back_modify;
278 extern BI_op_bind               monitor_back_bind;
279 extern BI_operational           monitor_back_operational;
280
281 LDAP_END_DECL
282
283 #endif /* _PROTO_BACK_MONITOR */
284