AzerothCore 3.3.5a
OpenSource WoW Emulator
Loading...
Searching...
No Matches
GridCell< WORLD_OBJECT_TYPES, GRID_OBJECT_TYPES > Class Template Reference

#include "GridCell.h"

Public Member Functions

 ~GridCell ()=default
 
template<class SPECIFIC_OBJECT >
void AddWorldObject (SPECIFIC_OBJECT *obj)
 
template<class SPECIFIC_OBJECT >
void AddGridObject (SPECIFIC_OBJECT *obj)
 
template<class T >
void Visit (TypeContainerVisitor< T, TypeMapContainer< GRID_OBJECT_TYPES > > &visitor)
 
template<class T >
void Visit (TypeContainerVisitor< T, TypeMapContainer< WORLD_OBJECT_TYPES > > &visitor)
 

Private Attributes

TypeMapContainer< GRID_OBJECT_TYPES > _gridObjects
 
TypeMapContainer< WORLD_OBJECT_TYPES > _worldObjects
 

Detailed Description

template<class WORLD_OBJECT_TYPES, class GRID_OBJECT_TYPES>
class GridCell< WORLD_OBJECT_TYPES, GRID_OBJECT_TYPES >

Constructor & Destructor Documentation

◆ ~GridCell()

template<class WORLD_OBJECT_TYPES , class GRID_OBJECT_TYPES >
GridCell< WORLD_OBJECT_TYPES, GRID_OBJECT_TYPES >::~GridCell ( )
default

Member Function Documentation

◆ AddGridObject()

template<class WORLD_OBJECT_TYPES , class GRID_OBJECT_TYPES >
template<class SPECIFIC_OBJECT >
void GridCell< WORLD_OBJECT_TYPES, GRID_OBJECT_TYPES >::AddGridObject ( SPECIFIC_OBJECT *  obj)
inline
53 {
54 _gridObjects.template insert<SPECIFIC_OBJECT>(obj);
55 ASSERT(obj->IsInGrid());
56 }
#define ASSERT
Definition Errors.h:68
TypeMapContainer< GRID_OBJECT_TYPES > _gridObjects
Definition GridCell.h:72

References GridCell< WORLD_OBJECT_TYPES, GRID_OBJECT_TYPES >::_gridObjects, and ASSERT.

Referenced by MapGrid< WORLD_OBJECT_TYPES, GRID_OBJECT_TYPES >::AddGridObject().

◆ AddWorldObject()

template<class WORLD_OBJECT_TYPES , class GRID_OBJECT_TYPES >
template<class SPECIFIC_OBJECT >
void GridCell< WORLD_OBJECT_TYPES, GRID_OBJECT_TYPES >::AddWorldObject ( SPECIFIC_OBJECT *  obj)
inline
47 {
48 _worldObjects.template insert<SPECIFIC_OBJECT>(obj);
49 ASSERT(obj->IsInGrid());
50 }
TypeMapContainer< WORLD_OBJECT_TYPES > _worldObjects
Definition GridCell.h:73

References GridCell< WORLD_OBJECT_TYPES, GRID_OBJECT_TYPES >::_worldObjects, and ASSERT.

Referenced by MapGrid< WORLD_OBJECT_TYPES, GRID_OBJECT_TYPES >::AddWorldObject().

◆ Visit() [1/2]

template<class WORLD_OBJECT_TYPES , class GRID_OBJECT_TYPES >
template<class T >
void GridCell< WORLD_OBJECT_TYPES, GRID_OBJECT_TYPES >::Visit ( TypeContainerVisitor< T, TypeMapContainer< GRID_OBJECT_TYPES > > &  visitor)
inline
61 {
62 visitor.Visit(_gridObjects);
63 }
void Visit(TYPE_CONTAINER &c)
Definition TypeContainerVisitor.h:88

References GridCell< WORLD_OBJECT_TYPES, GRID_OBJECT_TYPES >::_gridObjects.

Referenced by MapGrid< WORLD_OBJECT_TYPES, GRID_OBJECT_TYPES >::VisitCell().

◆ Visit() [2/2]

template<class WORLD_OBJECT_TYPES , class GRID_OBJECT_TYPES >
template<class T >
void GridCell< WORLD_OBJECT_TYPES, GRID_OBJECT_TYPES >::Visit ( TypeContainerVisitor< T, TypeMapContainer< WORLD_OBJECT_TYPES > > &  visitor)
inline

Member Data Documentation

◆ _gridObjects

template<class WORLD_OBJECT_TYPES , class GRID_OBJECT_TYPES >
TypeMapContainer<GRID_OBJECT_TYPES> GridCell< WORLD_OBJECT_TYPES, GRID_OBJECT_TYPES >::_gridObjects
private

◆ _worldObjects

template<class WORLD_OBJECT_TYPES , class GRID_OBJECT_TYPES >
TypeMapContainer<WORLD_OBJECT_TYPES> GridCell< WORLD_OBJECT_TYPES, GRID_OBJECT_TYPES >::_worldObjects
private

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