DGtal  1.1.0
Public Member Functions | Protected Attributes
DGtal::experimental::ImageContainerByHashTree< TDomain, TValue, THashKey >::Iterator Class Reference

Built-in iterator on an HashTree. This iterator visits all node in the tree. More...

#include <DGtal/images/ImageContainerByHashTree.h>

Collaboration diagram for DGtal::experimental::ImageContainerByHashTree< TDomain, TValue, THashKey >::Iterator:
[legend]

Public Member Functions

 Iterator (Node **data, unsigned int position, unsigned int arraySize)
 
bool isAtEnd () const
 
Valueoperator* ()
 
bool operator++ ()
 
bool operator== (const Iterator &it)
 
bool operator!= (const Iterator &it)
 
HashKey getKey () const
 
bool next ()
 

Protected Attributes

NodemyNode
 
unsigned int myCurrentCell
 
unsigned int myArraySize
 
Node ** myContainerData
 

Detailed Description

template<typename TDomain, typename TValue, typename THashKey = typename DGtal::uint64_t>
class DGtal::experimental::ImageContainerByHashTree< TDomain, TValue, THashKey >::Iterator

Built-in iterator on an HashTree. This iterator visits all node in the tree.

Iterator inner-class


Definition at line 495 of file ImageContainerByHashTree.h.

Constructor & Destructor Documentation

◆ Iterator()

template<typename TDomain , typename TValue , typename THashKey = typename DGtal::uint64_t>
DGtal::experimental::ImageContainerByHashTree< TDomain, TValue, THashKey >::Iterator::Iterator ( Node **  data,
unsigned int  position,
unsigned int  arraySize 
)
inline

Member Function Documentation

◆ getKey()

template<typename TDomain , typename TValue , typename THashKey = typename DGtal::uint64_t>
HashKey DGtal::experimental::ImageContainerByHashTree< TDomain, TValue, THashKey >::Iterator::getKey ( ) const
inline

◆ isAtEnd()

template<typename TDomain , typename TValue , typename THashKey = typename DGtal::uint64_t>
bool DGtal::experimental::ImageContainerByHashTree< TDomain, TValue, THashKey >::Iterator::isAtEnd ( ) const
inline

◆ next()

template<typename TDomain , typename TValue , typename THashKey = typename DGtal::uint64_t>
bool DGtal::experimental::ImageContainerByHashTree< TDomain, TValue, THashKey >::Iterator::next ( )

◆ operator!=()

template<typename TDomain , typename TValue , typename THashKey = typename DGtal::uint64_t>
bool DGtal::experimental::ImageContainerByHashTree< TDomain, TValue, THashKey >::Iterator::operator!= ( const Iterator it)
inline

Definition at line 528 of file ImageContainerByHashTree.h.

529  {
530  if (isAtEnd() && it.isAtEnd())
531  return false;
532  else
533  return (myNode != it.myNode);
534  }

References DGtal::experimental::ImageContainerByHashTree< TDomain, TValue, THashKey >::Iterator::isAtEnd(), and DGtal::experimental::ImageContainerByHashTree< TDomain, TValue, THashKey >::Iterator::myNode.

◆ operator*()

template<typename TDomain , typename TValue , typename THashKey = typename DGtal::uint64_t>
Value& DGtal::experimental::ImageContainerByHashTree< TDomain, TValue, THashKey >::Iterator::operator* ( )
inline

◆ operator++()

template<typename TDomain , typename TValue , typename THashKey = typename DGtal::uint64_t>
bool DGtal::experimental::ImageContainerByHashTree< TDomain, TValue, THashKey >::Iterator::operator++ ( )
inline

◆ operator==()

template<typename TDomain , typename TValue , typename THashKey = typename DGtal::uint64_t>
bool DGtal::experimental::ImageContainerByHashTree< TDomain, TValue, THashKey >::Iterator::operator== ( const Iterator it)
inline

Definition at line 521 of file ImageContainerByHashTree.h.

522  {
523  if (isAtEnd() && it.isAtEnd())
524  return true;
525  else
526  return (myNode == it.myNode);
527  }

References DGtal::experimental::ImageContainerByHashTree< TDomain, TValue, THashKey >::Iterator::isAtEnd(), and DGtal::experimental::ImageContainerByHashTree< TDomain, TValue, THashKey >::Iterator::myNode.

Field Documentation

◆ myArraySize

template<typename TDomain , typename TValue , typename THashKey = typename DGtal::uint64_t>
unsigned int DGtal::experimental::ImageContainerByHashTree< TDomain, TValue, THashKey >::Iterator::myArraySize
protected

◆ myContainerData

template<typename TDomain , typename TValue , typename THashKey = typename DGtal::uint64_t>
Node** DGtal::experimental::ImageContainerByHashTree< TDomain, TValue, THashKey >::Iterator::myContainerData
protected

◆ myCurrentCell

template<typename TDomain , typename TValue , typename THashKey = typename DGtal::uint64_t>
unsigned int DGtal::experimental::ImageContainerByHashTree< TDomain, TValue, THashKey >::Iterator::myCurrentCell
protected

◆ myNode

template<typename TDomain , typename TValue , typename THashKey = typename DGtal::uint64_t>
Node* DGtal::experimental::ImageContainerByHashTree< TDomain, TValue, THashKey >::Iterator::myNode
protected

The documentation for this class was generated from the following file:
DGtal::experimental::ImageContainerByHashTree::Iterator::myArraySize
unsigned int myArraySize
Definition: ImageContainerByHashTree.h:543
DGtal::experimental::ImageContainerByHashTree::Iterator::myNode
Node * myNode
Definition: ImageContainerByHashTree.h:541
DGtal::experimental::ImageContainerByHashTree::Iterator::next
bool next()
DGtal::experimental::ImageContainerByHashTree::Node::getObject
Value & getObject()
Definition: ImageContainerByHashTree.h:648
DGtal::experimental::ImageContainerByHashTree::Iterator::myContainerData
Node ** myContainerData
Definition: ImageContainerByHashTree.h:544
DGtal::experimental::ImageContainerByHashTree::Iterator::isAtEnd
bool isAtEnd() const
Definition: ImageContainerByHashTree.h:509
DGtal::experimental::ImageContainerByHashTree::Iterator::myCurrentCell
unsigned int myCurrentCell
Definition: ImageContainerByHashTree.h:542
DGtal::experimental::ImageContainerByHashTree::Node::getKey
HashKey getKey()
Definition: ImageContainerByHashTree.h:639