ACloudViewer  3.9.4
A Modern Library for 3D Data Processing
flann::IntervalHeap< T > Class Template Reference

#include <heap.h>

Public Member Functions

 IntervalHeap (int capacity)
 
size_t size ()
 
bool empty ()
 
void clear ()
 
void insert (const T &value)
 
bool popMin (T &value)
 
bool popMax (T &value)
 
bool getMin (T &value)
 
bool getMax (T &value)
 

Detailed Description

template<typename T>
class flann::IntervalHeap< T >

Definition at line 167 of file heap.h.

Constructor & Destructor Documentation

◆ IntervalHeap()

template<typename T >
flann::IntervalHeap< T >::IntervalHeap ( int  capacity)
inline

Constructor.

Params: size = heap size

Definition at line 191 of file heap.h.

References size_.

Member Function Documentation

◆ clear()

template<typename T >
void flann::IntervalHeap< T >::clear ( )
inline

Clears the heap.

Definition at line 216 of file heap.h.

References size_.

Referenced by flann::BoundedHeap< T >::clear().

◆ empty()

template<typename T >
bool flann::IntervalHeap< T >::empty ( )
inline

Tests if the heap is empty

Returns
true is heap empty, false otherwise

Definition at line 208 of file heap.h.

References size_.

Referenced by flann::BoundedHeap< T >::empty().

◆ getMax()

template<typename T >
bool flann::IntervalHeap< T >::getMax ( T &  value)
inline

Definition at line 390 of file heap.h.

References size_.

Referenced by flann::BoundedHeap< T >::insert().

◆ getMin()

template<typename T >
bool flann::IntervalHeap< T >::getMin ( T &  value)
inline

Definition at line 380 of file heap.h.

References size_.

◆ insert()

template<typename T >
void flann::IntervalHeap< T >::insert ( const T &  value)
inline

Definition at line 221 of file heap.h.

References size_.

Referenced by flann::BoundedHeap< T >::insert().

◆ popMax()

template<typename T >
bool flann::IntervalHeap< T >::popMax ( T &  value)
inline

Returns the element of maximum value from the heap

Parameters
value
Returns
false if heap empty

Definition at line 340 of file heap.h.

References size_, and std::swap().

Referenced by flann::BoundedHeap< T >::insert().

◆ popMin()

template<typename T >
bool flann::IntervalHeap< T >::popMin ( T &  value)
inline

Returns the node of minimum value from the heap

Parameters
valueout parameter used to return the min element
Returns
false if heap empty

Definition at line 295 of file heap.h.

References size_, and std::swap().

Referenced by flann::BoundedHeap< T >::popMin().

◆ size()

template<typename T >
size_t flann::IntervalHeap< T >::size ( )
inline
Returns
Heap size

Definition at line 199 of file heap.h.

References size_.

Referenced by flann::BoundedHeap< T >::insert(), and flann::BoundedHeap< T >::size().


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