source: trunk/minix/servers/inet/generic/event.h@ 15

Last change on this file since 15 was 9, checked in by Mattia Monga, 14 years ago

Minix 3.1.2a

File size: 781 bytes
RevLine 
[9]1/*
2inet/generic/event.h
3
4Created: April 1995 by Philip Homburg <philip@f-mnx.phicoh.com>
5
6Header file for an event mechanism.
7
8Copyright 1995 Philip Homburg
9*/
10
11#ifndef INET__GENERIC__EVENT_H
12#define INET__GENERIC__EVENT_H
13
14struct event;
15
16typedef union ev_arg
17{
18 int ev_int;
19 void *ev_ptr;
20} ev_arg_t;
21
22typedef void (*ev_func_t) ARGS(( struct event *ev, union ev_arg eva ));
23
24typedef struct event
25{
26 ev_func_t ev_func;
27 ev_arg_t ev_arg;
28 struct event *ev_next;
29} event_t;
30
31extern event_t *ev_head;
32
33void ev_init ARGS(( event_t *ev ));
34void ev_enqueue ARGS(( event_t *ev, ev_func_t func, ev_arg_t ev_arg ));
35void ev_process ARGS(( void ));
36int ev_in_queue ARGS(( event_t *ev ));
37
38#endif /* INET__GENERIC__EVENT_H */
39
40/*
41 * $PchId: event.h,v 1.5 2004/08/03 16:23:49 philip Exp $
42 */
Note: See TracBrowser for help on using the repository browser.