Public Types | Public Member Functions | Private Attributes | List of all members
rtflann::KNNResultSet2< DistanceType > Class Template Reference

#include <result_set.h>

Inheritance diagram for rtflann::KNNResultSet2< DistanceType >:
Inheritance graph
[legend]

Public Types

typedef DistanceIndex< DistanceType > DistIndex
 

Public Member Functions

void addPoint (DistanceType dist, size_t index)
 
void clear ()
 
void copy (size_t *indices, DistanceType *dists, size_t num_elements, bool sorted=true)
 
bool full () const
 
 KNNResultSet2 (size_t capacity_)
 
size_t size () const
 
DistanceType worstDist () const
 
 ~KNNResultSet2 ()
 
- Public Member Functions inherited from rtflann::ResultSet< DistanceType >
virtual ~ResultSet ()
 

Private Attributes

size_t capacity_
 
std::vector< DistIndexdist_index_
 
bool is_full_
 
DistanceType worst_dist_
 

Detailed Description

template<typename DistanceType>
class rtflann::KNNResultSet2< DistanceType >

Definition at line 304 of file result_set.h.

Member Typedef Documentation

◆ DistIndex

template<typename DistanceType>
typedef DistanceIndex<DistanceType> rtflann::KNNResultSet2< DistanceType >::DistIndex

Definition at line 307 of file result_set.h.

Constructor & Destructor Documentation

◆ KNNResultSet2()

template<typename DistanceType>
rtflann::KNNResultSet2< DistanceType >::KNNResultSet2 ( size_t  capacity_)
inline

Definition at line 309 of file result_set.h.

◆ ~KNNResultSet2()

template<typename DistanceType>
rtflann::KNNResultSet2< DistanceType >::~KNNResultSet2 ( )
inline

Definition at line 317 of file result_set.h.

Member Function Documentation

◆ addPoint()

template<typename DistanceType>
void rtflann::KNNResultSet2< DistanceType >::addPoint ( DistanceType  dist,
size_t  index 
)
inlinevirtual

Add another point to result set

Parameters
distdistance to point
indexindex of point Pre-conditions: capacity_>0

Implements rtflann::ResultSet< DistanceType >.

Definition at line 355 of file result_set.h.

◆ clear()

template<typename DistanceType>
void rtflann::KNNResultSet2< DistanceType >::clear ( )
inline

Clears the result set

Definition at line 324 of file result_set.h.

◆ copy()

template<typename DistanceType>
void rtflann::KNNResultSet2< DistanceType >::copy ( size_t *  indices,
DistanceType *  dists,
size_t  num_elements,
bool  sorted = true 
)
inline

Copy indices and distances to output buffers

Parameters
indices
dists
num_elementsNumber of elements to copy
sortedIndicates if results should be sorted

Definition at line 388 of file result_set.h.

◆ full()

template<typename DistanceType>
bool rtflann::KNNResultSet2< DistanceType >::full ( ) const
inlinevirtual

Radius search result set always reports full

Returns

Implements rtflann::ResultSet< DistanceType >.

Definition at line 344 of file result_set.h.

◆ size()

template<typename DistanceType>
size_t rtflann::KNNResultSet2< DistanceType >::size ( ) const
inline
Returns
Number of elements in the result set

Definition at line 335 of file result_set.h.

◆ worstDist()

template<typename DistanceType>
DistanceType rtflann::KNNResultSet2< DistanceType >::worstDist ( ) const
inlinevirtual

Implements rtflann::ResultSet< DistanceType >.

Definition at line 408 of file result_set.h.

Member Data Documentation

◆ capacity_

template<typename DistanceType>
size_t rtflann::KNNResultSet2< DistanceType >::capacity_
private

Definition at line 414 of file result_set.h.

◆ dist_index_

template<typename DistanceType>
std::vector<DistIndex> rtflann::KNNResultSet2< DistanceType >::dist_index_
private

Definition at line 416 of file result_set.h.

◆ is_full_

template<typename DistanceType>
bool rtflann::KNNResultSet2< DistanceType >::is_full_
private

Definition at line 417 of file result_set.h.

◆ worst_dist_

template<typename DistanceType>
DistanceType rtflann::KNNResultSet2< DistanceType >::worst_dist_
private

Definition at line 415 of file result_set.h.


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


rtabmap
Author(s): Mathieu Labbe
autogenerated on Mon Jan 23 2023 03:39:00