pcb 4.1.1
An interactive printed circuit board layout editor.
|
00001 00039 #ifndef PCB_HEAP_H 00040 #define PCB_HEAP_H 00041 00042 #include "global.h" 00043 00047 typedef double cost_t; 00051 typedef struct heap_struct heap_t; 00052 00053 heap_t *heap_create (); 00054 void heap_destroy (heap_t ** heap); 00055 void heap_free (heap_t * heap, void (*funcfree) (void *)); 00056 00057 /* -- mutation -- */ 00058 void heap_insert (heap_t * heap, cost_t cost, void *data); 00059 void *heap_remove_smallest (heap_t * heap); 00060 void *heap_replace (heap_t * heap, cost_t cost, void *data); 00061 00062 /* -- interrogation -- */ 00063 int heap_is_empty (heap_t * heap); 00064 int heap_size (heap_t * heap); 00065 00066 #endif /* PCB_HEAP_H */