HDK
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
UT_PriorityQueue< utPtr, utCompare, need_changed_position > Class Template Reference

#include <UT_PriorityQueue.h>

Public Member Functions

 UT_PriorityQueue (unsigned int sz=0, const utCompare &compare=utCompare())
 Trivial constructor and destructor: More...
 
virtual ~UT_PriorityQueue ()
 
 UT_PriorityQueue (const UT_PriorityQueue< utPtr, utCompare, need_changed_position > &a)
 
unsigned int insert (utPtr t)
 
unsigned int append (utPtr t)
 
void destroy (unsigned int entry)
 calls remove before destroying More...
 
void remove (unsigned int entry)
 
void clear ()
 
exint size () const
 
exint entries () const
 
int64 getMemoryUsage (bool inclusive) const
 
bool isEmpty () const
 
const utPtr & head () const
 
const utPtr & getEntry (int idx) const
 
virtual void changedPosition (utPtr, unsigned int) const
 
unsigned int bubbleDown (unsigned int entry)
 
unsigned int bubbleUp (unsigned int entry)
 

Protected Attributes

UT_Array< utPtr > myArray
 
const utCompare comparator
 

Detailed Description

template<class utPtr, class utCompare = std::less<utPtr>, bool need_changed_position = false>
class UT_PriorityQueue< utPtr, utCompare, need_changed_position >

Definition at line 25 of file UT_PriorityQueue.h.

Constructor & Destructor Documentation

template<class utPtr, class utCompare = std::less<utPtr>, bool need_changed_position = false>
UT_PriorityQueue< utPtr, utCompare, need_changed_position >::UT_PriorityQueue ( unsigned int  sz = 0,
const utCompare &  compare = utCompare() 
)
inlineexplicit

Trivial constructor and destructor:

Definition at line 29 of file UT_PriorityQueue.h.

template<class utPtr, class utCompare = std::less<utPtr>, bool need_changed_position = false>
virtual UT_PriorityQueue< utPtr, utCompare, need_changed_position >::~UT_PriorityQueue ( )
inlinevirtual

Definition at line 34 of file UT_PriorityQueue.h.

template<class utPtr, class utCompare = std::less<utPtr>, bool need_changed_position = false>
UT_PriorityQueue< utPtr, utCompare, need_changed_position >::UT_PriorityQueue ( const UT_PriorityQueue< utPtr, utCompare, need_changed_position > &  a)
inline

Copy constructor that uses operator '=' to assign each of a's Things to this array.

Definition at line 38 of file UT_PriorityQueue.h.

Member Function Documentation

template<class utPtr, class utCompare = std::less<utPtr>, bool need_changed_position = false>
unsigned int UT_PriorityQueue< utPtr, utCompare, need_changed_position >::append ( utPtr  t)
inline

Definition at line 52 of file UT_PriorityQueue.h.

template<class utPtr, class utCompare = std::less<utPtr>, bool need_changed_position = false>
unsigned int UT_PriorityQueue< utPtr, utCompare, need_changed_position >::bubbleDown ( unsigned int  entry)
inline

Definition at line 115 of file UT_PriorityQueue.h.

template<class utPtr, class utCompare = std::less<utPtr>, bool need_changed_position = false>
unsigned int UT_PriorityQueue< utPtr, utCompare, need_changed_position >::bubbleUp ( unsigned int  entry)
inline

Definition at line 157 of file UT_PriorityQueue.h.

template<class utPtr, class utCompare = std::less<utPtr>, bool need_changed_position = false>
virtual void UT_PriorityQueue< utPtr, utCompare, need_changed_position >::changedPosition ( utPtr  ,
unsigned  int 
) const
inlinevirtual

Reimplemented in gu_sdf_queue.

Definition at line 111 of file UT_PriorityQueue.h.

template<class utPtr, class utCompare = std::less<utPtr>, bool need_changed_position = false>
void UT_PriorityQueue< utPtr, utCompare, need_changed_position >::clear ( void  )
inline

Definition at line 82 of file UT_PriorityQueue.h.

template<class utPtr, class utCompare = std::less<utPtr>, bool need_changed_position = false>
void UT_PriorityQueue< utPtr, utCompare, need_changed_position >::destroy ( unsigned int  entry)
inline

calls remove before destroying

Definition at line 59 of file UT_PriorityQueue.h.

template<class utPtr, class utCompare = std::less<utPtr>, bool need_changed_position = false>
exint UT_PriorityQueue< utPtr, utCompare, need_changed_position >::entries ( void  ) const
inline

Definition at line 88 of file UT_PriorityQueue.h.

template<class utPtr, class utCompare = std::less<utPtr>, bool need_changed_position = false>
const utPtr& UT_PriorityQueue< utPtr, utCompare, need_changed_position >::getEntry ( int  idx) const
inline

Definition at line 105 of file UT_PriorityQueue.h.

template<class utPtr, class utCompare = std::less<utPtr>, bool need_changed_position = false>
int64 UT_PriorityQueue< utPtr, utCompare, need_changed_position >::getMemoryUsage ( bool  inclusive) const
inline

Definition at line 90 of file UT_PriorityQueue.h.

template<class utPtr, class utCompare = std::less<utPtr>, bool need_changed_position = false>
const utPtr& UT_PriorityQueue< utPtr, utCompare, need_changed_position >::head ( ) const
inline

Definition at line 100 of file UT_PriorityQueue.h.

template<class utPtr, class utCompare = std::less<utPtr>, bool need_changed_position = false>
unsigned int UT_PriorityQueue< utPtr, utCompare, need_changed_position >::insert ( utPtr  t)
inline

Definition at line 44 of file UT_PriorityQueue.h.

template<class utPtr, class utCompare = std::less<utPtr>, bool need_changed_position = false>
bool UT_PriorityQueue< utPtr, utCompare, need_changed_position >::isEmpty ( ) const
inline

Definition at line 97 of file UT_PriorityQueue.h.

template<class utPtr, class utCompare = std::less<utPtr>, bool need_changed_position = false>
void UT_PriorityQueue< utPtr, utCompare, need_changed_position >::remove ( unsigned int  entry)
inline

Definition at line 66 of file UT_PriorityQueue.h.

template<class utPtr, class utCompare = std::less<utPtr>, bool need_changed_position = false>
exint UT_PriorityQueue< utPtr, utCompare, need_changed_position >::size ( void  ) const
inline

Definition at line 87 of file UT_PriorityQueue.h.

Member Data Documentation

template<class utPtr, class utCompare = std::less<utPtr>, bool need_changed_position = false>
const utCompare UT_PriorityQueue< utPtr, utCompare, need_changed_position >::comparator
protected

Definition at line 216 of file UT_PriorityQueue.h.

template<class utPtr, class utCompare = std::less<utPtr>, bool need_changed_position = false>
UT_Array<utPtr> UT_PriorityQueue< utPtr, utCompare, need_changed_position >::myArray
protected

Definition at line 215 of file UT_PriorityQueue.h.


The documentation for this class was generated from the following file: