design_pattern_for_c  V 1.00
event_threadpool_data.h
Go to the documentation of this file.
1 
5 #ifndef EVENT_THREADPOOL_DATA_H_
6 #define EVENT_THREADPOOL_DATA_H_
7 
16 
17 
18 #define EV_TPOOL_READ (0x01<<0)
19 #define EV_TPOOL_WRITE (0x01<<1)
20 #define EV_TPOOL_HUNGUP (0x01<<2)
21 
26  int fd;
27  int eventflag;
28  void (*event_callback)(int socketfd, int eventflag, void * event_arg);
29 };
30 
33 
39 
42  int result;
44 };
45 
47 
49 #endif
struct event_subscriber_t * EventSubscriber
void(* event_callback)(int socketfd, int eventflag, void *event_arg)
EventTPoolManager class instance definition.
EventSubscriber class instance definition, this is storaged in any threads.
struct event_tpool_manager_t * EventTPoolManager
EventTPoolManager class definition.
int eventflag
OR value of EV_TPOOL_XXX definition.
int fd
file descripter of this subscriber
struct event_tpool_thread_info_t * EventTPoolThreadInfo
EventTPoolThreadInfo event_handle
add result definition