void pqueue_print(pqueue_t *q, pqueue_print_entry_f print)
Definition pqueue_base.c:300
int(* pqueue_cmp_pri_f)(pqueue_pri_t next, pqueue_pri_t curr)
Definition pqueue_base.h:58
void * pqueue_find_same_priority(pqueue_t *q, void *e)
Definition pqueue_base.c:207
size_t(* pqueue_get_pos_f)(void *a)
Definition pqueue_base.h:64
pqueue_t * pqueue_init(size_t n, pqueue_cmp_pri_f cmppri, pqueue_get_pri_f getpri, pqueue_get_pos_f getpos, pqueue_set_pos_f setpos, pqueue_eq_elem_f eqelem, pqueue_print_entry_f prt)
Allocate and initialize a priority queue.
Definition pqueue_base.c:128
int(* pqueue_eq_elem_f)(void *next, void *curr)
Definition pqueue_base.h:61
void * pqueue_pop(pqueue_t *q)
Definition pqueue_base.c:248
void(* pqueue_print_entry_f)(void *a)
Definition pqueue_base.h:70
int pqueue_remove(pqueue_t *q, void *e)
Definition pqueue_base.c:235
void * pqueue_find_equal_same_priority(pqueue_t *q, void *e)
Definition pqueue_base.c:209
void * pqueue_peek(pqueue_t *q)
Definition pqueue_base.c:282
void pqueue_empty_into(pqueue_t **dest, pqueue_t **src)
Empty 'src' into 'dest'.
Definition pqueue_base.c:261
pqueue_pri_t(* pqueue_get_pri_f)(void *a)
Definition pqueue_base.h:55
void pqueue_free(pqueue_t *q)
Definition pqueue_base.c:152
unsigned long long pqueue_pri_t
Definition pqueue_base.h:52
void pqueue_dump(pqueue_t *q, pqueue_print_entry_f print)
Definition pqueue_base.c:290
int pqueue_insert(pqueue_t *q, void *d)
Definition pqueue_base.c:211
size_t pqueue_size(pqueue_t *q)
Definition pqueue_base.c:157
int pqueue_is_valid(pqueue_t *q)
Definition pqueue_base.c:353
void(* pqueue_set_pos_f)(void *a, size_t pos)
Definition pqueue_base.h:67
Definition pqueue_base.h:73
pqueue_set_pos_f setpos
Definition pqueue_base.h:80
pqueue_get_pos_f getpos
Definition pqueue_base.h:79
pqueue_eq_elem_f eqelem
Definition pqueue_base.h:81
size_t avail
Definition pqueue_base.h:75
size_t size
Definition pqueue_base.h:74
void ** d
Definition pqueue_base.h:83
size_t step
Definition pqueue_base.h:76
pqueue_get_pri_f getpri
Definition pqueue_base.h:78
pqueue_print_entry_f prt
Definition pqueue_base.h:82
pqueue_cmp_pri_f cmppri
Definition pqueue_base.h:77