size_t max_pq_size(const t_max_pq *pq)
Returns the number of keys in this queue.
void max_pq_delete(t_max_pq *pq)
Deletes this queue and free all its items and the associated data.
t_max_pq * max_pq_new(const t_type *type)
Initializes a new empty priority queue.
void max_pq_add(t_max_pq *pq, const void *data)
Adds a copy of the specified element to the queue.
void * max_pq_pop(t_max_pq *pq)
Removes and returns the largest key in this queue.
void * max_pq_peek(const t_max_pq *pq)
Returns the largest key in the queue.
t_max_pq * max_pq_copy(const t_max_pq *pq)
Copies the queue and all it contents.
A full representation of a data type, used to achieve polymorphism in the implementation of data stru...
t_array t_max_pq
A priority queue of generic keys.