argos::CSpaceHashUpdater< ENTITY > Class Template Referenceabstract

Defines the basic cell updater of the space hash. More...

#include <space_hash.h>

Public Member Functions

virtual ~CSpaceHashUpdater ()
 Class destructor. More...
 
virtual void operator() (CAbstractSpaceHash< ENTITY > &c_space_hash, ENTITY &c_entity)=0
 Updates the necessary cells of a space hash. More...
 

Detailed Description

template<class ENTITY>
class argos::CSpaceHashUpdater< ENTITY >

Defines the basic cell updater of the space hash.

If you want to store your entities in a space hash, you need to implement this interface. The aim of this class is to call CAbstractSpaceHash::UpdateCell() for each cell in which the entity must be contained.

Parameters
EntityThe type of entity held by the corresponding space hash
See also
CSpaceHash

Definition at line 269 of file space_hash.h.

Constructor & Destructor Documentation

◆ ~CSpaceHashUpdater()

template<class ENTITY >
virtual argos::CSpaceHashUpdater< ENTITY >::~CSpaceHashUpdater ( )
inlinevirtual

Class destructor.

Definition at line 276 of file space_hash.h.

Member Function Documentation

◆ operator()()

template<class ENTITY >
virtual void argos::CSpaceHashUpdater< ENTITY >::operator() ( CAbstractSpaceHash< ENTITY > &  c_space_hash,
ENTITY &  c_entity 
)
pure virtual

Updates the necessary cells of a space hash.

Parameters
c_space_hashThe space hash to update
c_entityThe entity indexed by the space hash.

Implemented in argos::CTagEntitySpaceHashUpdater, argos::CRadioEntitySpaceHashUpdater, argos::CRABEquippedEntitySpaceHashUpdater, argos::CLEDEntitySpaceHashUpdater, and argos::CDirectionalLEDEntitySpaceHashUpdater.