VOX
A little voxel engine
Loading...
Searching...
No Matches
ecs::SparseSet< entityType > Class Template Reference

#include <SparseSet.hpp>

Collaboration diagram for ecs::SparseSet< entityType >:
Collaboration graph

Public Types

typedef entityType node_type
 
typedef std::vector< node_typedense_type
 
typedef std::vector< size_t > sparse_type
 
typedef dense_type::iterator iterator
 
typedef dense_type::const_iterator const_iterator
 
typedef dense_type::reverse_iterator reverse_iterator
 
typedef dense_type::const_reverse_iterator const_reverse_iterator
 

Public Member Functions

 SparseSet ()
 
 SparseSet (size_t size)
 
virtual ~SparseSet ()=default
 
 SparseSet (SparseSet &other)=default
 
 SparseSet (SparseSet &&other)=default
 
SparseSetoperator= (SparseSet &other)=default
 
SparseSetoperator= (SparseSet &&other)=default
 
size_t insert (entityType entity)
 
virtual size_t remove (entityType entity)
 
size_t index (entityType entity) const
 
bool contains (entityType entity) const
 
size_t size () const
 
iterator begin ()
 
const_iterator begin () const
 
reverse_iterator rbegin ()
 
const_reverse_iterator rbegin () const
 
iterator end ()
 
const_iterator end () const
 
reverse_iterator rend ()
 
const_reverse_iterator rend () const
 

Member Typedef Documentation

◆ const_iterator

template<ValidEntity entityType>
typedef dense_type::const_iterator ecs::SparseSet< entityType >::const_iterator

◆ const_reverse_iterator

template<ValidEntity entityType>
typedef dense_type::const_reverse_iterator ecs::SparseSet< entityType >::const_reverse_iterator

◆ dense_type

template<ValidEntity entityType>
typedef std::vector<node_type> ecs::SparseSet< entityType >::dense_type

◆ iterator

template<ValidEntity entityType>
typedef dense_type::iterator ecs::SparseSet< entityType >::iterator

◆ node_type

template<ValidEntity entityType>
typedef entityType ecs::SparseSet< entityType >::node_type

◆ reverse_iterator

template<ValidEntity entityType>
typedef dense_type::reverse_iterator ecs::SparseSet< entityType >::reverse_iterator

◆ sparse_type

template<ValidEntity entityType>
typedef std::vector<size_t> ecs::SparseSet< entityType >::sparse_type

Constructor & Destructor Documentation

◆ SparseSet() [1/4]

template<ValidEntity entityType>
ecs::SparseSet< entityType >::SparseSet ( )
inline

◆ SparseSet() [2/4]

template<ValidEntity entityType>
ecs::SparseSet< entityType >::SparseSet ( size_t  size)
inline

◆ ~SparseSet()

template<ValidEntity entityType>
virtual ecs::SparseSet< entityType >::~SparseSet ( )
virtualdefault

◆ SparseSet() [3/4]

template<ValidEntity entityType>
ecs::SparseSet< entityType >::SparseSet ( SparseSet< entityType > &  other)
default

◆ SparseSet() [4/4]

template<ValidEntity entityType>
ecs::SparseSet< entityType >::SparseSet ( SparseSet< entityType > &&  other)
default

Member Function Documentation

◆ begin() [1/2]

template<ValidEntity entityType>
iterator ecs::SparseSet< entityType >::begin ( )
inline

◆ begin() [2/2]

template<ValidEntity entityType>
const_iterator ecs::SparseSet< entityType >::begin ( ) const
inline

◆ contains()

template<ValidEntity entityType>
bool ecs::SparseSet< entityType >::contains ( entityType  entity) const
inline

◆ end() [1/2]

template<ValidEntity entityType>
iterator ecs::SparseSet< entityType >::end ( )
inline

◆ end() [2/2]

template<ValidEntity entityType>
const_iterator ecs::SparseSet< entityType >::end ( ) const
inline

◆ index()

template<ValidEntity entityType>
size_t ecs::SparseSet< entityType >::index ( entityType  entity) const
inline

◆ insert()

template<ValidEntity entityType>
size_t ecs::SparseSet< entityType >::insert ( entityType  entity)
inline

◆ operator=() [1/2]

template<ValidEntity entityType>
SparseSet & ecs::SparseSet< entityType >::operator= ( SparseSet< entityType > &&  other)
default

◆ operator=() [2/2]

template<ValidEntity entityType>
SparseSet & ecs::SparseSet< entityType >::operator= ( SparseSet< entityType > &  other)
default

◆ rbegin() [1/2]

template<ValidEntity entityType>
reverse_iterator ecs::SparseSet< entityType >::rbegin ( )
inline

◆ rbegin() [2/2]

template<ValidEntity entityType>
const_reverse_iterator ecs::SparseSet< entityType >::rbegin ( ) const
inline

◆ remove()

template<ValidEntity entityType>
virtual size_t ecs::SparseSet< entityType >::remove ( entityType  entity)
inlinevirtual

◆ rend() [1/2]

template<ValidEntity entityType>
reverse_iterator ecs::SparseSet< entityType >::rend ( )
inline

◆ rend() [2/2]

template<ValidEntity entityType>
const_reverse_iterator ecs::SparseSet< entityType >::rend ( ) const
inline

◆ size()

template<ValidEntity entityType>
size_t ecs::SparseSet< entityType >::size ( ) const
inline

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