Fix the mess with ldb includes.
[metze/samba/wip.git] / source4 / lib / ldb / ldb_tdb / ldb_tdb.h
index 223181ca0bd20bf1486ee3cc8ec4ce607fba220f..7ebf199f6f5c3a64a418ef81229d50cc809f272d 100644 (file)
@@ -6,6 +6,8 @@
 #include "tdb.h"
 #endif
 
+#include "ldb_module.h"
+
 /* this private structure is used by the ltdb backend in the
    ldb_context */
 struct ltdb_private {
@@ -33,6 +35,7 @@ struct ltdb_private {
        int in_transaction;
 
        bool check_base;
+       struct ltdb_idxptr *idxptr;
 };
 
 /*
@@ -50,12 +53,14 @@ struct ltdb_context {
        struct ldb_dn *base;
        enum ldb_scope scope;
        const char * const *attrs;
+       struct tevent_timer *timeout_event;
 };
 
 /* special record types */
 #define LTDB_INDEX      "@INDEX"
 #define LTDB_INDEXLIST  "@INDEXLIST"
 #define LTDB_IDX        "@IDX"
+#define LTDB_IDXPTR     "@IDXPTR"
 #define LTDB_IDXATTR    "@IDXATTR"
 #define LTDB_IDXONE     "@IDXONE"
 #define LTDB_BASEINFO   "@BASEINFO"
@@ -84,6 +89,9 @@ int ltdb_index_add(struct ldb_module *module, const struct ldb_message *msg);
 int ltdb_index_del(struct ldb_module *module, const struct ldb_message *msg);
 int ltdb_index_one(struct ldb_module *module, const struct ldb_message *msg, int add);
 int ltdb_reindex(struct ldb_module *module);
+int ltdb_index_transaction_start(struct ldb_module *module);
+int ltdb_index_transaction_commit(struct ldb_module *module);
+int ltdb_index_transaction_cancel(struct ldb_module *module);
 
 /* The following definitions come from lib/ldb/ldb_tdb/ldb_pack.c  */
 
@@ -112,6 +120,8 @@ int ltdb_filter_attrs(struct ldb_message *msg, const char * const *attrs);
 int ltdb_search(struct ltdb_context *ctx);
 
 /* The following definitions come from lib/ldb/ldb_tdb/ldb_tdb.c  */
+int ltdb_lock_read(struct ldb_module *module);
+int ltdb_unlock_read(struct ldb_module *module);
 struct TDB_DATA ltdb_key(struct ldb_module *module, struct ldb_dn *dn);
 int ltdb_store(struct ldb_module *module, const struct ldb_message *msg, int flgs);
 int ltdb_delete_noindex(struct ldb_module *module, struct ldb_dn *dn);