Alps  2.0.2
Public Member Functions | Private Member Functions | Private Attributes | List of all members
AlpsPriorityQueue< T > Class Template Reference

#include <AlpsPriorityQueue.h>

+ Inheritance diagram for AlpsPriorityQueue< T >:

Public Member Functions

 AlpsPriorityQueue ()
 
 AlpsPriorityQueue (AlpsSearchStrategy< T > &compare)
 
const std::vector< T > & getContainer () const
 Return a const reference to the container. More...
 
void setComparison (AlpsSearchStrategy< T > &c)
 Set comparison function and resort heap. More...
 
top () const
 Return the top element of the heap. More...
 
void push (T x)
 Add a element to the heap. More...
 
void pop ()
 Remove the top element from the heap. More...
 
bool empty () const
 Return true for an empty vector. More...
 
size_t size () const
 Return the size of the vector. More...
 
void clear ()
 Remove all elements from the vector. More...
 

Private Member Functions

 AlpsPriorityQueue (const AlpsPriorityQueue &)
 
AlpsPriorityQueueoperator= (const AlpsPriorityQueue &)
 

Private Attributes

std::vector< T > vec_
 
AlpsCompare< T > comparison_
 

Detailed Description

template<class T>
class AlpsPriorityQueue< T >

Definition at line 38 of file AlpsPriorityQueue.h.

Constructor & Destructor Documentation

◆ AlpsPriorityQueue() [1/3]

template<class T >
AlpsPriorityQueue< T >::AlpsPriorityQueue ( const AlpsPriorityQueue< T > &  )
private

◆ AlpsPriorityQueue() [2/3]

template<class T >
AlpsPriorityQueue< T >::AlpsPriorityQueue ( )
inline

Definition at line 48 of file AlpsPriorityQueue.h.

◆ AlpsPriorityQueue() [3/3]

template<class T >
AlpsPriorityQueue< T >::AlpsPriorityQueue ( AlpsSearchStrategy< T > &  compare)
inline

Definition at line 49 of file AlpsPriorityQueue.h.

Member Function Documentation

◆ operator=()

template<class T >
AlpsPriorityQueue& AlpsPriorityQueue< T >::operator= ( const AlpsPriorityQueue< T > &  )
private

◆ getContainer()

template<class T >
const std::vector<T>& AlpsPriorityQueue< T >::getContainer ( ) const
inline

Return a const reference to the container.

Definition at line 54 of file AlpsPriorityQueue.h.

◆ setComparison()

template<class T >
void AlpsPriorityQueue< T >::setComparison ( AlpsSearchStrategy< T > &  c)
inline

Set comparison function and resort heap.

Definition at line 57 of file AlpsPriorityQueue.h.

◆ top()

template<class T >
T AlpsPriorityQueue< T >::top ( ) const
inline

Return the top element of the heap.

Definition at line 63 of file AlpsPriorityQueue.h.

◆ push()

template<class T >
void AlpsPriorityQueue< T >::push ( x)
inline

Add a element to the heap.

Definition at line 66 of file AlpsPriorityQueue.h.

◆ pop()

template<class T >
void AlpsPriorityQueue< T >::pop ( )
inline

Remove the top element from the heap.

Definition at line 72 of file AlpsPriorityQueue.h.

◆ empty()

template<class T >
bool AlpsPriorityQueue< T >::empty ( ) const
inline

Return true for an empty vector.

Definition at line 78 of file AlpsPriorityQueue.h.

◆ size()

template<class T >
size_t AlpsPriorityQueue< T >::size ( ) const
inline

Return the size of the vector.

Definition at line 83 of file AlpsPriorityQueue.h.

◆ clear()

template<class T >
void AlpsPriorityQueue< T >::clear ( )
inline

Remove all elements from the vector.

But not delete them.

Definition at line 88 of file AlpsPriorityQueue.h.

Member Data Documentation

◆ vec_

template<class T >
std::vector<T> AlpsPriorityQueue< T >::vec_
private

Definition at line 44 of file AlpsPriorityQueue.h.

◆ comparison_

template<class T >
AlpsCompare<T> AlpsPriorityQueue< T >::comparison_
private

Definition at line 45 of file AlpsPriorityQueue.h.


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