Skip to content
Myr

fdm.h

This file

Path

fdm.h

19 lines · 515 bytes · C

Last changed by

Not known.

History of this file

Take it

1#pragma once23#include <stdbool.h>45struct fdm;67typedef bool (*fdm_handler_t)(struct fdm *fdm, int fd, int events, void *data);89struct fdm *fdm_init(void);10void fdm_destroy(struct fdm *fdm);1112bool fdm_add(struct fdm *fdm, int fd, int events, fdm_handler_t handler, void *data);13bool fdm_del(struct fdm *fdm, int fd);14bool fdm_del_no_close(struct fdm *fdm, int fd);1516bool fdm_event_add(struct fdm *fdm, int fd, int events);17bool fdm_event_del(struct fdm *fdm, int fd, int events);1819bool fdm_poll(struct fdm *fdm);