libcortex
Event loop library following a "batteries included" approach
Loading...
Searching...
No Matches
src
pipe.h
1
#ifndef _CRTX_PIPE_H
2
#define _CRTX_PIPE_H
3
4
#ifdef __cplusplus
5
extern
"C"
{
6
#endif
7
8
/*
9
* Mario Kicherer (dev@kicherer.org) 2018
10
*
11
*/
12
13
#define CRTX_READ_END (0)
14
#define CRTX_WRITE_END (1)
15
16
struct
crtx_pipe_listener
{
17
struct
crtx_listener_base
base;
18
19
int
fds[2];
20
char
*event_type;
21
22
crtx_handle_task_t fd_event_handler;
23
void
*fd_event_handler_data;
24
25
int
fd_flags;
26
};
27
28
struct
crtx_listener_base
*crtx_setup_pipe_listener(
void
*options);
29
void
crtx_pipe_clear_lstnr(
struct
crtx_pipe_listener
*lstnr);
30
CRTX_DECLARE_ALLOC_FUNCTION(pipe)
31
32
void
crtx_pipe_init();
33
void
crtx_pipe_finish();
34
35
#ifdef __cplusplus
36
}
37
#endif
38
39
#endif
crtx_listener_base
base structure of a listener
Definition
core.h:186
crtx_pipe_listener
Definition
pipe.h:16
Generated by
1.9.8