cheshirekow  v0.1.0
mpblocks::kd_tree::ListBuilder< Traits > Struct Template Reference

Enumerates an entire subtree, building a list of nodes along with the hyperectangle bounding the subtree at that node. More...

#include <mpblocks/kd_tree/ListBuilder.h>

Public Types

typedef std::deque< Pair_t * > Deque_t
 
typedef Traits::Format_t Format_t
 
typedef Traits::HyperRect HyperRect_t
 
typedef std::list< Pair_t * > List_t
 
typedef Traits::Node Node_t
 
typedef ListPair< TraitsPair_t
 
typedef Vector_t Point_t
 
typedef Eigen::Matrix
< Format_t, Traits::NDim, 1 > 
Vector_t
 

Public Member Functions

template<typename Inserter_t >
void build (Node_t *root, Inserter_t ins)
 build an enumeration of the tree More...
 
void buildBFS (Node_t *root)
 enumerate a subtree in breadth-first manner More...
 
void buildDFS (Node_t *root)
 enumerate a subtree in depth-first manner More...
 
List_tgetList ()
 return the list More...
 
void reset ()
 delete all stored data and get ready for another search More...
 

Private Attributes

Deque_t m_deque
 
HyperRect_t m_hyper
 
List_t m_list
 

Detailed Description

template<class Traits>
struct mpblocks::kd_tree::ListBuilder< Traits >

Enumerates an entire subtree, building a list of nodes along with the hyperectangle bounding the subtree at that node.

Note
lists can be built in breadth first or depth first order

Definition at line 42 of file ListBuilder.h.

Member Typedef Documentation

template<class Traits >
typedef std::deque<Pair_t*> mpblocks::kd_tree::ListBuilder< Traits >::Deque_t

Definition at line 55 of file ListBuilder.h.

template<class Traits >
typedef Traits::Format_t mpblocks::kd_tree::ListBuilder< Traits >::Format_t

Definition at line 45 of file ListBuilder.h.

Definition at line 47 of file ListBuilder.h.

template<class Traits >
typedef std::list<Pair_t*> mpblocks::kd_tree::ListBuilder< Traits >::List_t

Definition at line 56 of file ListBuilder.h.

template<class Traits >
typedef Traits::Node mpblocks::kd_tree::ListBuilder< Traits >::Node_t

Definition at line 46 of file ListBuilder.h.

template<class Traits >
typedef ListPair<Traits> mpblocks::kd_tree::ListBuilder< Traits >::Pair_t

Definition at line 54 of file ListBuilder.h.

template<class Traits >
typedef Vector_t mpblocks::kd_tree::ListBuilder< Traits >::Point_t

Definition at line 50 of file ListBuilder.h.

template<class Traits >
typedef Eigen::Matrix<Format_t,Traits::NDim,1> mpblocks::kd_tree::ListBuilder< Traits >::Vector_t

Definition at line 49 of file ListBuilder.h.

Member Function Documentation

template<class Traits >
template<typename Inserter_t >
void mpblocks::kd_tree::ListBuilder< Traits >::build ( Node_t root,
Inserter_t  ins 
)

build an enumeration of the tree

Template Parameters
Inserter_ttype of the insert iterator
Parameters
rootroot of the subtree to build
insthe inserter where we put nodes we enumerate should be an insertion iterator

Definition at line 59 of file ListBuilder.hpp.

template<class Traits >
void mpblocks::kd_tree::ListBuilder< Traits >::buildBFS ( Node_t root)

enumerate a subtree in breadth-first manner

Definition at line 79 of file ListBuilder.hpp.

template<class Traits >
void mpblocks::kd_tree::ListBuilder< Traits >::buildDFS ( Node_t root)

enumerate a subtree in depth-first manner

Definition at line 89 of file ListBuilder.hpp.

template<class Traits >
std::list< ListPair< Traits > * > & mpblocks::kd_tree::ListBuilder< Traits >::getList ( )

return the list

Definition at line 97 of file ListBuilder.hpp.

template<class Traits >
void mpblocks::kd_tree::ListBuilder< Traits >::reset ( )

delete all stored data and get ready for another search

Definition at line 38 of file ListBuilder.hpp.

Member Data Documentation

template<class Traits >
Deque_t mpblocks::kd_tree::ListBuilder< Traits >::m_deque
private

Definition at line 59 of file ListBuilder.h.

template<class Traits >
HyperRect_t mpblocks::kd_tree::ListBuilder< Traits >::m_hyper
private

Definition at line 61 of file ListBuilder.h.

template<class Traits >
List_t mpblocks::kd_tree::ListBuilder< Traits >::m_list
private

Definition at line 60 of file ListBuilder.h.


The documentation for this struct was generated from the following files: