Logo ROOT  
Reference Guide
 
Loading...
Searching...
No Matches
priorityq.c File Reference
#include "gluos.h"
#include <stddef.h>
#include <assert.h>
#include <limits.h>
#include "memalloc.h"
#include "priorityq-heap.c"
#include "priorityq-sort.h"
Include dependency graph for priorityq.c:

Macros

#define GT(x, y)   (! LEQ(x,y))
 
#define LT(x, y)   (! LEQ(y,x))
 
#define Swap(a, b)   do{PQkey *tmp = *a; *a = *b; *b = tmp;}while(0)
 

Functions

void __gl_pqSortDelete (PriorityQSort *pq, PQSortHandle curr)
 
void __gl_pqSortDeletePriorityQ (PriorityQSort *pq)
 
PQSortKey __gl_pqSortExtractMin (PriorityQSort *pq)
 
int __gl_pqSortInit (PriorityQSort *pq)
 
PQSortHandle __gl_pqSortInsert (PriorityQSort *pq, PQSortKey keyNew)
 
int __gl_pqSortIsEmpty (PriorityQSort *pq)
 
PQSortKey __gl_pqSortMinimum (PriorityQSort *pq)
 
PriorityQSort__gl_pqSortNewPriorityQ (int(*leq)(PQSortKey key1, PQSortKey key2))
 

Macro Definition Documentation

◆ GT

#define GT (   x,
  y 
)    (! LEQ(x,y))

Definition at line 88 of file priorityq.c.

◆ LT

#define LT (   x,
  y 
)    (! LEQ(y,x))

Definition at line 87 of file priorityq.c.

◆ Swap

#define Swap (   a,
  b 
)    do{PQkey *tmp = *a; *a = *b; *b = tmp;}while(0)

Definition at line 89 of file priorityq.c.

Function Documentation

◆ __gl_pqSortDelete()

void __gl_pqSortDelete ( PriorityQSort pq,
PQSortHandle  curr 
)

Definition at line 248 of file priorityq.c.

◆ __gl_pqSortDeletePriorityQ()

void __gl_pqSortDeletePriorityQ ( PriorityQSort pq)

Definition at line 77 of file priorityq.c.

◆ __gl_pqSortExtractMin()

PQSortKey __gl_pqSortExtractMin ( PriorityQSort pq)

Definition at line 203 of file priorityq.c.

◆ __gl_pqSortInit()

int __gl_pqSortInit ( PriorityQSort pq)

Definition at line 92 of file priorityq.c.

◆ __gl_pqSortInsert()

PQSortHandle __gl_pqSortInsert ( PriorityQSort pq,
PQSortKey  keyNew 
)

Definition at line 174 of file priorityq.c.

◆ __gl_pqSortIsEmpty()

int __gl_pqSortIsEmpty ( PriorityQSort pq)

Definition at line 242 of file priorityq.c.

◆ __gl_pqSortMinimum()

PQSortKey __gl_pqSortMinimum ( PriorityQSort pq)

Definition at line 224 of file priorityq.c.

◆ __gl_pqSortNewPriorityQ()

PriorityQSort * __gl_pqSortNewPriorityQ ( int(*)(PQSortKey key1, PQSortKey key2)  leq)

Definition at line 50 of file priorityq.c.