about summary refs log tree commit diff
path: root/evloop/timeheap.h
blob: 8a712c506d7b3832c31cbe2ab521024877a0ff6c (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
#ifndef BTPD_TIMEHEAP_H
#define BTPD_TIMEHEAP_H

struct th_handle {
    int i;
    void *data;
};

int timeheap_init(void);
int timeheap_size(void);

int  timeheap_insert(struct th_handle *h, struct timespec *t);
void timeheap_remove(struct th_handle *h);
void timeheap_change(struct th_handle *h, struct timespec *t);

void *timeheap_remove_top(void);
struct timespec timeheap_top(void);

#endif