Ponca  a6685bea814e743eaa6c9284aa218d7d97a6527c
Point Cloud Analysis library
Loading...
Searching...
No Matches
Ponca::NeighborGraphOneConnectedIterator< ContainerPtr, Index > Class Template Reference

Base iterator class for NeighborGraphOneConnectedQuery. More...

#include <neighborGraphOneConnectedIterator.h>

+ Collaboration diagram for Ponca::NeighborGraphOneConnectedIterator< ContainerPtr, Index >:

Public Types

using iterator_category = std::input_iterator_tag
 
using difference_type = std::ptrdiff_t
 
using value_type = Index
 
using pointer = ContainerPtr
 
using reference = const Index &
 
using Self = NeighborGraphOneConnectedIterator< ContainerPtr, Index >
 

Public Member Functions

 NeighborGraphOneConnectedIterator (ContainerPtr data)
 
 NeighborGraphOneConnectedIterator (ContainerPtr data, Index i)
 
bool operator!= (const NeighborGraphOneConnectedIterator &other) const
 Inequality operand.
 
bool operator== (const NeighborGraphOneConnectedIterator &other) const
 Equality operand.
 
NeighborGraphOneConnectedIteratoroperator++ ()
 Equality operand.
 
reference operator* () const
 Dereference operator.
 
Self operator++ (Index)
 Postfix increment.
 
void operator+= (const Index i)
 Value increment.
 
Self operator+ (const Index i)
 Plus operator.
 

Protected Attributes

ContainerPtr m_data
 
Index m_i {0}
 

Detailed Description

template<typename ContainerPtr, typename Index>
class Ponca::NeighborGraphOneConnectedIterator< ContainerPtr, Index >

Base iterator class for NeighborGraphOneConnectedQuery.

As this is an input iterator, we don't guarantee anything other than reading the values with it. If you need to operate on the values of this iterator with algorithms that relies on forward iterator functionalities, you should copy the index values in an STL-like container.

Warning
This iterator object should never be duplicated, as it is a proxy that holds a reference to the actual data : the copy of this iterator would still point to the same NeighborGraph reference. So, modifying one will modify the others and can result in incorrect values.

Definition at line 26 of file neighborGraphOneConnectedIterator.h.

Member Typedef Documentation

◆ difference_type

template<typename ContainerPtr , typename Index >
using Ponca::NeighborGraphOneConnectedIterator< ContainerPtr, Index >::difference_type = std::ptrdiff_t

Definition at line 30 of file neighborGraphOneConnectedIterator.h.

◆ iterator_category

template<typename ContainerPtr , typename Index >
using Ponca::NeighborGraphOneConnectedIterator< ContainerPtr, Index >::iterator_category = std::input_iterator_tag

Definition at line 29 of file neighborGraphOneConnectedIterator.h.

◆ pointer

◆ reference

Definition at line 33 of file neighborGraphOneConnectedIterator.h.

◆ Self

◆ value_type

Definition at line 31 of file neighborGraphOneConnectedIterator.h.

Constructor & Destructor Documentation

◆ NeighborGraphOneConnectedIterator() [1/2]

template<typename ContainerPtr , typename Index >
Ponca::NeighborGraphOneConnectedIterator< ContainerPtr, Index >::NeighborGraphOneConnectedIterator ( ContainerPtr  data)
inline

Definition at line 36 of file neighborGraphOneConnectedIterator.h.

◆ NeighborGraphOneConnectedIterator() [2/2]

template<typename ContainerPtr , typename Index >
Ponca::NeighborGraphOneConnectedIterator< ContainerPtr, Index >::NeighborGraphOneConnectedIterator ( ContainerPtr  data,
Index  i 
)
inline

Definition at line 38 of file neighborGraphOneConnectedIterator.h.

Member Function Documentation

◆ operator!=()

Inequality operand.

Definition at line 41 of file neighborGraphOneConnectedIterator.h.

◆ operator*()

template<typename ContainerPtr , typename Index >
reference Ponca::NeighborGraphOneConnectedIterator< ContainerPtr, Index >::operator* ( ) const
inline

Dereference operator.

Definition at line 60 of file neighborGraphOneConnectedIterator.h.

◆ operator+()

template<typename ContainerPtr , typename Index >
Self Ponca::NeighborGraphOneConnectedIterator< ContainerPtr, Index >::operator+ ( const Index  i)
inline

Plus operator.

Definition at line 74 of file neighborGraphOneConnectedIterator.h.

◆ operator++() [1/2]

Equality operand.

Definition at line 53 of file neighborGraphOneConnectedIterator.h.

◆ operator++() [2/2]

template<typename ContainerPtr , typename Index >
Self Ponca::NeighborGraphOneConnectedIterator< ContainerPtr, Index >::operator++ ( Index  )
inline

Postfix increment.

Definition at line 63 of file neighborGraphOneConnectedIterator.h.

◆ operator+=()

template<typename ContainerPtr , typename Index >
void Ponca::NeighborGraphOneConnectedIterator< ContainerPtr, Index >::operator+= ( const Index  i)
inline

Value increment.

Definition at line 71 of file neighborGraphOneConnectedIterator.h.

◆ operator==()

Equality operand.

Definition at line 47 of file neighborGraphOneConnectedIterator.h.

Member Data Documentation

◆ m_data

◆ m_i

template<typename ContainerPtr , typename Index >
Index Ponca::NeighborGraphOneConnectedIterator< ContainerPtr, Index >::m_i {0}
protected

Definition at line 78 of file neighborGraphOneConnectedIterator.h.