ompl::NearestNeighbors< _T > Class Template Reference

Abstract representation of a container that can perform nearest neighbors queries. More...

#include <NearestNeighbors.h>

Inheritance diagram for ompl::NearestNeighbors< _T >:
Inheritance graph
[legend]

List of all members.

Public Types

typedef boost::function2
< double, const _T &, const _T & > 
DistanceFunction
 The definition of a distance function.

Public Member Functions

virtual void add (std::vector< _T > &data)
 Add a vector of points.
virtual void add (_T &data)=0
 Add an element to the datastructure.
virtual void clear (void)=0
 Clear the datastructure.
const DistanceFunctiongetDistanceFunction (void) const
 Get the distance function used.
virtual void list (std::vector< _T > &data) const =0
 Get all the elements in the datastructure.
virtual _T nearest (const _T &data) const =0
 Get the nearest neighbor of a point.
virtual void nearestK (const _T &data, std::size_t k, std::vector< _T > &nbh) const =0
 Get the k-nearest neighbors of a point.
 NearestNeighbors (void)
virtual void nearestR (const _T &data, double radius, std::vector< _T > &nbh) const =0
 Get the nearest neighbors of a point, within a specified radius.
virtual bool remove (_T &data)=0
 Remove an element from the datastructure.
void setDistanceFunction (const DistanceFunction &distFun)
 Set the distance function to use.
virtual std::size_t size (void) const =0
 Get the number of elements in the datastructure.
virtual ~NearestNeighbors (void)

Protected Attributes

DistanceFunction distFun_
 The used distance function.

Detailed Description

template<typename _T>
class ompl::NearestNeighbors< _T >

Abstract representation of a container that can perform nearest neighbors queries.

Definition at line 49 of file NearestNeighbors.h.


Member Typedef Documentation

template<typename _T>
typedef boost::function2<double, const _T&, const _T&> ompl::NearestNeighbors< _T >::DistanceFunction

The definition of a distance function.

Definition at line 54 of file NearestNeighbors.h.


Constructor & Destructor Documentation

template<typename _T>
ompl::NearestNeighbors< _T >::NearestNeighbors ( void   )  [inline]

Definition at line 56 of file NearestNeighbors.h.

template<typename _T>
virtual ompl::NearestNeighbors< _T >::~NearestNeighbors ( void   )  [inline, virtual]

Definition at line 60 of file NearestNeighbors.h.


Member Function Documentation

template<typename _T>
virtual void ompl::NearestNeighbors< _T >::add ( std::vector< _T > &  data  )  [inline, virtual]

Add a vector of points.

Reimplemented in ompl::NearestNeighborsLinear< _T >, and ompl::NearestNeighborsSqrtApprox< _T >.

Definition at line 83 of file NearestNeighbors.h.

template<typename _T>
virtual void ompl::NearestNeighbors< _T >::add ( _T &  data  )  [pure virtual]

Add an element to the datastructure.

Implemented in ompl::NearestNeighborsLinear< _T >, and ompl::NearestNeighborsSqrtApprox< _T >.

template<typename _T>
virtual void ompl::NearestNeighbors< _T >::clear ( void   )  [pure virtual]

Clear the datastructure.

Implemented in ompl::NearestNeighborsLinear< _T >, and ompl::NearestNeighborsSqrtApprox< _T >.

template<typename _T>
const DistanceFunction& ompl::NearestNeighbors< _T >::getDistanceFunction ( void   )  const [inline]

Get the distance function used.

Definition at line 71 of file NearestNeighbors.h.

template<typename _T>
virtual void ompl::NearestNeighbors< _T >::list ( std::vector< _T > &  data  )  const [pure virtual]

Get all the elements in the datastructure.

Implemented in ompl::NearestNeighborsLinear< _T >.

template<typename _T>
virtual _T ompl::NearestNeighbors< _T >::nearest ( const _T &  data  )  const [pure virtual]

Get the nearest neighbor of a point.

Implemented in ompl::NearestNeighborsLinear< _T >, and ompl::NearestNeighborsSqrtApprox< _T >.

template<typename _T>
virtual void ompl::NearestNeighbors< _T >::nearestK ( const _T &  data,
std::size_t  k,
std::vector< _T > &  nbh 
) const [pure virtual]

Get the k-nearest neighbors of a point.

Implemented in ompl::NearestNeighborsLinear< _T >.

template<typename _T>
virtual void ompl::NearestNeighbors< _T >::nearestR ( const _T &  data,
double  radius,
std::vector< _T > &  nbh 
) const [pure virtual]

Get the nearest neighbors of a point, within a specified radius.

Implemented in ompl::NearestNeighborsLinear< _T >.

template<typename _T>
virtual bool ompl::NearestNeighbors< _T >::remove ( _T &  data  )  [pure virtual]

Remove an element from the datastructure.

Implemented in ompl::NearestNeighborsLinear< _T >, and ompl::NearestNeighborsSqrtApprox< _T >.

template<typename _T>
void ompl::NearestNeighbors< _T >::setDistanceFunction ( const DistanceFunction distFun  )  [inline]

Set the distance function to use.

Definition at line 65 of file NearestNeighbors.h.

template<typename _T>
virtual std::size_t ompl::NearestNeighbors< _T >::size ( void   )  const [pure virtual]

Get the number of elements in the datastructure.

Implemented in ompl::NearestNeighborsLinear< _T >.


Member Data Documentation

template<typename _T>
DistanceFunction ompl::NearestNeighbors< _T >::distFun_ [protected]

The used distance function.

Definition at line 110 of file NearestNeighbors.h.


The documentation for this class was generated from the following file:
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines


ompl
Author(s): Ioan Sucan/isucan@rice.edu, Mark Moll/mmoll@rice.edu, Lydia Kavraki/kavraki@rice.edu
autogenerated on Fri Jan 11 09:33:58 2013