Separate malloc debug library. Removal of ASN_COMPILED-#ifdefs.
[yaz-moved-to-github.git] / zoom / zoom-p.h
index 3383d34..5958aff 100644 (file)
@@ -1,13 +1,15 @@
 /*
  * Private C header for ZOOM C.
- * $Id: zoom-p.h,v 1.1 2001-10-23 21:00:20 adam Exp $
+ * $Id: zoom-p.h,v 1.4 2001-11-13 22:57:03 adam Exp $
  */
 #include <yaz/proto.h>
 #include <yaz/comstack.h>
 #include <yaz/wrbuf.h>
 #include <yaz/zoom.h>
 
-struct Z3950_search_p {
+typedef struct Z3950_Event_p *Z3950_Event;
+
+struct Z3950_query_p {
     Z_Query *query;
     Z_SortKeySpecList *sort_spec;
     int refcount;
@@ -20,6 +22,7 @@ struct Z3950_search_p {
 
 #define Z3950_SELECT_READ 1
 #define Z3950_SELECT_WRITE 2
+#define Z3950_SELECT_EXCEPT 4
 
 struct Z3950_connection_p {
     COMSTACK cs;
@@ -38,10 +41,11 @@ struct Z3950_connection_p {
     char *cookie_out;
     char *cookie_in;
     int async;
-    int event_pending;
     Z3950_task tasks;
     Z3950_options options;
     Z3950_resultset resultsets;
+    Z3950_Event m_queue_front;
+    Z3950_Event m_queue_back;
 };
 
 
@@ -64,7 +68,7 @@ typedef struct Z3950_record_cache_p *Z3950_record_cache;
 struct Z3950_resultset_p {
     Z_Query *r_query;
     Z_SortKeySpecList *r_sort_spec;
-    Z3950_search search;
+    Z3950_query search;
     int refcount;
     int size;
     int start;
@@ -98,11 +102,18 @@ struct Z3950_task_p {
        Z3950_resultset resultset;
 #define Z3950_TASK_RETRIEVE 2
        /** also resultset here */
-
+#define Z3950_TASK_CONNECT 3
     } u;
     Z3950_task next;
 };
 
+struct Z3950_Event_p {
+    int kind;
+    Z3950_Event next;
+    Z3950_Event prev;
+};
+
+
 #ifndef YAZ_DATE
 COMSTACK cs_create_host(const char *type_and_host, int blocking, void **vp);
 Odr_oid *yaz_str_to_z3950oid (ODR o, int oid_class, const char *str);