Detailed Description
Functions | |
SCIP_EXPORT SCIP_RETCODE | GCGpqueueCreate (SCIP *scip, GCG_PQUEUE **pqueue, int initsize, SCIP_DECL_SORTPTRCOMP((*ptrcomp))) |
SCIP_EXPORT void | GCGpqueueFree (GCG_PQUEUE **pqueue) |
SCIP_EXPORT void | GCGpqueueClear (GCG_PQUEUE *pqueue) |
SCIP_EXPORT SCIP_RETCODE | GCGpqueueInsert (GCG_PQUEUE *pqueue, void *elem) |
SCIP_EXPORT void * | GCGpqueueRemove (GCG_PQUEUE *pqueue) |
SCIP_EXPORT SCIP_RETCODE | GCGpqueueResort (GCG_PQUEUE *pqueue) |
SCIP_RETCODE | GCGpqueueSetComperator (GCG_PQUEUE *pqueue, SCIP_DECL_SORTPTRCOMP((*ptrcomp))) |
SCIP_RETCODE | GCGpqueueDelete (GCG_PQUEUE *pqueue, int pos, void **elem) |
SCIP_EXPORT void * | GCGpqueueFirst (GCG_PQUEUE *pqueue) |
SCIP_EXPORT int | GCGpqueueNElems (GCG_PQUEUE *pqueue) |
SCIP_EXPORT void ** | GCGpqueueElems (GCG_PQUEUE *pqueue) |
Function Documentation
◆ GCGpqueueCreate()
SCIP_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()
SCIP_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()
SCIP_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()
SCIP_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()
SCIP_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()
SCIP_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()
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()
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()
SCIP_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()
SCIP_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()
SCIP_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.