Added --with-yc option to configure. For the data1_node in data1.h:
[yaz-moved-to-github.git] / server / eventl.h
index 129bf30..17dae69 100644 (file)
@@ -4,7 +4,19 @@
  * Sebastian Hammer, Adam Dickmeiss
  *
  * $Log: eventl.h,v $
- * Revision 1.6  1995-05-16 08:51:02  quinn
+ * Revision 1.10  1998-01-29 13:30:23  adam
+ * Better event handle system for NT/Unix.
+ *
+ * Revision 1.9  1997/09/01 09:31:48  adam
+ * Removed definition statserv_remove from statserv.h to eventl.h.
+ *
+ * Revision 1.8  1995/06/19 12:39:09  quinn
+ * Fixed bug in timeout code. Added BER dumper.
+ *
+ * Revision 1.7  1995/06/16  10:31:34  quinn
+ * Added session timeout.
+ *
+ * Revision 1.6  1995/05/16  08:51:02  quinn
  * License, documentation, and memory fixes
  *
  * Revision 1.5  1995/05/15  11:56:37  quinn
@@ -28,6 +40,8 @@
 #ifndef EVENTL_H
 #define EVENTL_H
 
+#include <time.h>
+
 struct iochan;
 
 typedef void (*IOC_CALLBACK)(struct iochan *i, int event);
@@ -45,6 +59,8 @@ int force_event;
     IOC_CALLBACK fun;
     void *data;
     int destroyed;
+    time_t last_event;
+    time_t max_idle;
     
     struct iochan *next;
 } *IOCHAN;
@@ -63,9 +79,9 @@ int force_event;
 #define iochan_setfun(i, d) ((i)->fun = d)
 #define iochan_setevent(i, e) ((i)->force_event = (e))
 #define iochan_getnext(i) ((i)->next)
+#define iochan_settimeout(i, t) ((i)->max_idle = (t), (i)->last_event = time(0))
 
-IOCHAN iochan_getchan(void);
 IOCHAN iochan_create(int fd, IOC_CALLBACK cb, int flags);
-int event_loop();
-
+int event_loop(IOCHAN *iochans);
+void statserv_remove (IOCHAN pIOChannel);
 #endif