Detailed Description
Functions | |
GCG_EXPORT SCIP_RETCODE | GCGpqueueCreate (SCIP *scip, GCG_PQUEUE **pqueue, int initsize, SCIP_DECL_SORTPTRCOMP((*ptrcomp))) |
GCG_EXPORT void | GCGpqueueFree (GCG_PQUEUE **pqueue) |
GCG_EXPORT void | GCGpqueueClear (GCG_PQUEUE *pqueue) |
GCG_EXPORT SCIP_RETCODE | GCGpqueueInsert (GCG_PQUEUE *pqueue, void *elem) |
GCG_EXPORT void * | GCGpqueueRemove (GCG_PQUEUE *pqueue) |
GCG_EXPORT SCIP_RETCODE | GCGpqueueResort (GCG_PQUEUE *pqueue) |
GCG_EXPORT SCIP_RETCODE | GCGpqueueSetComperator (GCG_PQUEUE *pqueue, SCIP_DECL_SORTPTRCOMP((*ptrcomp))) |
GCG_EXPORT SCIP_RETCODE | GCGpqueueDelete (GCG_PQUEUE *pqueue, int pos, void **elem) |
GCG_EXPORT void * | GCGpqueueFirst (GCG_PQUEUE *pqueue) |
GCG_EXPORT int | GCGpqueueNElems (GCG_PQUEUE *pqueue) |
GCG_EXPORT void ** | GCGpqueueElems (GCG_PQUEUE *pqueue) |
Function Documentation
◆ GCGpqueueCreate()
GCG_EXPORT SCIP_RETCODE GCGpqueueCreate | ( | SCIP * | scip, |
GCG_PQUEUE ** | pqueue, | ||
int | initsize, | ||
SCIP_DECL_SORTPTRCOMP((*ptrcomp)) | |||
) |
creates priority queue
Definition at line 118 of file gcgpqueue.c.
References pqueueResize().
Referenced by gcg::Pricingcontroller::initSol().
◆ GCGpqueueFree()
GCG_EXPORT void GCGpqueueFree | ( | GCG_PQUEUE ** | pqueue | ) |
frees priority queue, but not the data elements themselves
Definition at line 142 of file gcgpqueue.c.
Referenced by gcg::Pricingcontroller::exitSol().
◆ GCGpqueueClear()
GCG_EXPORT void GCGpqueueClear | ( | GCG_PQUEUE * | pqueue | ) |
clears the priority queue, but doesn't free the data elements themselves
Definition at line 153 of file gcgpqueue.c.
References GCG_PQueue::len.
Referenced by gcg::Pricingcontroller::setupPriorityQueue().
◆ GCGpqueueInsert()
GCG_EXPORT SCIP_RETCODE GCGpqueueInsert | ( | GCG_PQUEUE * | pqueue, |
void * | elem | ||
) |
inserts element into priority queue
Definition at line 163 of file gcgpqueue.c.
References GCG_PQueue::len, PQ_PARENT, pqueueResize(), and GCG_PQueue::slots.
Referenced by gcg::Pricingcontroller::evaluatePricingjob(), and gcg::Pricingcontroller::setupPriorityQueue().
◆ GCGpqueueRemove()
GCG_EXPORT void* GCGpqueueRemove | ( | GCG_PQUEUE * | pqueue | ) |
removes and returns best element from the priority queue
Definition at line 193 of file gcgpqueue.c.
References GCG_PQueue::len, PQ_LEFTCHILD, PQ_PARENT, PQ_RIGHTCHILD, and GCG_PQueue::slots.
Referenced by gcg::Pricingcontroller::getNextPricingjob().
◆ GCGpqueueResort()
GCG_EXPORT SCIP_RETCODE GCGpqueueResort | ( | GCG_PQUEUE * | pqueue | ) |
resorts priority queue after changing the key values
Definition at line 234 of file gcgpqueue.c.
References GCG_PQueue::len, PQ_PARENT, and pqueueHeapify().
Referenced by gcg::Pricingcontroller::pricingprobNextBranchcons().
◆ GCGpqueueSetComperator()
GCG_EXPORT SCIP_RETCODE GCGpqueueSetComperator | ( | GCG_PQUEUE * | pqueue, |
SCIP_DECL_SORTPTRCOMP((*ptrcomp)) | |||
) |
set the comperator of the priority queue delete item at position pos and insert last item at this position and resort pqueue
set the comperator of the priority queue
Definition at line 261 of file gcgpqueue.c.
◆ GCGpqueueDelete()
GCG_EXPORT SCIP_RETCODE GCGpqueueDelete | ( | GCG_PQUEUE * | pqueue, |
int | pos, | ||
void ** | elem | ||
) |
< delete item at position pos and insert last item at this position and resort pqueue
Definition at line 274 of file gcgpqueue.c.
References GCG_PQueue::len, PQ_LEFTCHILD, PQ_PARENT, PQ_RIGHTCHILD, and GCG_PQueue::slots.
◆ GCGpqueueFirst()
GCG_EXPORT void* GCGpqueueFirst | ( | GCG_PQUEUE * | pqueue | ) |
returns the best element of the queue without removing it
Definition at line 313 of file gcgpqueue.c.
References GCG_PQueue::len, and GCG_PQueue::slots.
◆ GCGpqueueNElems()
GCG_EXPORT int GCGpqueueNElems | ( | GCG_PQUEUE * | pqueue | ) |
returns the number of elements in the queue
Definition at line 327 of file gcgpqueue.c.
References GCG_PQueue::len.
◆ GCGpqueueElems()
GCG_EXPORT void** GCGpqueueElems | ( | GCG_PQUEUE * | pqueue | ) |
returns the elements of the queue; changing the returned array may destroy the queue's ordering!
Definition at line 338 of file gcgpqueue.c.
References GCG_PQueue::len, and GCG_PQueue::slots.