change the libctdb_ prefix to ctdb_
[sahlberg/ctdb.git] / include / ctdb.h
index d3c0d79ec4f80784a14b0e9636175f87c6e04686..dd5361c1782b0e1adb117e0ca33ffd13a5f75812 100644 (file)
 #ifndef _CTDB_H
 #define _CTDB_H
 
-/* all functions except libctdb_connect() and libctdb_service()
- * are non-blocking
- */
-
-struct ctdb_context *libctdb_connect(const char *addr);
+struct ctdb_context *ctdb_connect(const char *addr);
 
-int libctdb_get_fd(struct ctdb_context *ctdb);
+int ctdb_get_fd(struct ctdb_context *ctdb);
 
-int libctdb_which_events(struct ctdb_context *ctdb);
+int ctdb_which_events(struct ctdb_context *ctdb);
 
-int libctdb_service(struct ctdb_context *ctdb);
+int ctdb_service(struct ctdb_context *ctdb);
 
 
 
-typedef void libctdb_handle;
+typedef void ctdb_handle;
 
 
-typedef void (*get_recmaster_cb)(int32_t status, int32_t recmaster, void *private_data);
+/*
+ * function to cancel a request/call
+ */
+int ctdb_cancel(ctdb_handle *);
 
 
+/*
+ * functions to read the recovery master of a node
+ */
+typedef void (*get_recmaster_cb)(int32_t status, int32_t recmaster, void *private_data);
 
-libctdb_handle *
-libctdb_getrecmaster_send(struct ctdb_context *ctdb,
+ctdb_handle *
+ctdb_getrecmaster_send(struct ctdb_context *ctdb,
                        uint32_t destnode,
                        get_recmaster_cb callback,
                        void *private_data);
-int libctdb_getrecmaster_recv(struct ctdb_context *ctdb,
-                       libctdb_handle *handle,
+int ctdb_getrecmaster_recv(struct ctdb_context *ctdb,
+                       ctdb_handle *handle,
                        uint32_t *recmaster);
-int libctdb_getrecmaster(struct ctdb_context *ctdb,
+int ctdb_getrecmaster(struct ctdb_context *ctdb,
                        uint32_t destnode,
                        uint32_t *recmaster);
 
 
-int libctdb_cancel(libctdb_handle *);
-
 #endif