Space-efficient geometric algorithms and data structures

By Ilya Katz and Hervé Brönnimann    

inplaceds::kd_tree< _Point, _AxisAlignedGeometry, _Sequence > Class Template Reference

#include <kd_tree.hpp>


Detailed Description

template<class _Point, class _AxisAlignedGeometry, class _Sequence = std::vector<_Point>>
class inplaceds::kd_tree< _Point, _AxisAlignedGeometry, _Sequence >

Definition at line 26 of file kd_tree.hpp.

Public Types

typedef _Sequence::value_type point_type
typedef _Sequence::iterator iterator
typedef _Sequence::const_iterator const_iterator
typedef _AxisAlignedGeometry geometry
typedef _Sequence sequence

Public Member Functions

 kd_tree ()
 Creates an empty kd-tree.
template<class InputIterator>
 kd_tree (InputIterator first, InputIterator last)
 Creates a kd-tree from the copy of the range [first, last).
 kd_tree (const _Sequence &lhs)
 Creates a kd-tree from the copy of lhs.
 kd_tree (const kd_tree &lhs)
 Create a kd-tree as the copy of lhs.
void insert (point_type p)
 Inserts point p into kd-tree.
void remove (iterator pos)
 Removes the point at position pos.
const_iterator find (point_type p) const
 Finds the location of point p in the kd-tree. If element is not present npos() is returned.
const_iterator npos () const
 Returns iteteror that indicates that a value is not found.
template<class Box>
iterator box_query (Box Q, sequence &result) const
 Queries a kd-tree with a box query.
template<class Halfplane>
iterator halfplane_query (Halfplane Q, sequence &result) const
 Queries a kd-tree with a halfplane query.
template<class Comp>
iterator query (Comp Q, sequence &result) const
 Queries a kd-tree with a halfplane query.
const_iterator points () const
 Returns const iterator to the underlying collection of points.


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

Code Documentation generated Using Doxygen

Copyright © Ilya Katz and Hervé Brönnimann, 2005, 2006.