Horizon Official Technical Documentation
TypeListIterator Namespace Reference

Functions

template<class SPECIFIC_TYPE >
SPECIFIC_TYPE * Insert (ContainerMapList< SPECIFIC_TYPE > &elements, SPECIFIC_TYPE *obj)
 
template<class SPECIFIC_TYPE >
SPECIFIC_TYPE * Insert (ContainerMapList< TypeNull > &, SPECIFIC_TYPE *)
 
template<class SPECIFIC_TYPE , class T >
SPECIFIC_TYPE * Insert (ContainerMapList< T > &, SPECIFIC_TYPE *)
 
template<class SPECIFIC_TYPE , class HEAD , class TAIL >
SPECIFIC_TYPE * Insert (ContainerMapList< TypeList< HEAD, TAIL > > &elements, SPECIFIC_TYPE *obj)
 
template<class SPECIFIC_TYPE >
size_t count (ContainerMapList< SPECIFIC_TYPE > const &elements, SPECIFIC_TYPE *)
 
template<class SPECIFIC_TYPE >
size_t count (ContainerMapList< TypeNull > const &, SPECIFIC_TYPE *)
 
template<class SPECIFIC_TYPE , class T >
size_t count (ContainerMapList< T > const &, SPECIFIC_TYPE *)
 
template<class SPECIFIC_TYPE , class T >
size_t count (ContainerMapList< TypeList< SPECIFIC_TYPE, T > > const &elements, SPECIFIC_TYPE *fake)
 
template<class SPECIFIC_TYPE , class H , class T >
size_t count (ContainerMapList< TypeList< H, T > > const &elements, SPECIFIC_TYPE *fake)
 
template<class TypeNull >
size_t count_all (ContainerMapList< TypeNull > const &elements)
 
template<class H , class T >
size_t count_all (ContainerMapList< TypeList< H, T > > const &elements)
 

Function Documentation

◆ count() [1/5]

template<class SPECIFIC_TYPE >
size_t TypeListIterator::count ( ContainerMapList< SPECIFIC_TYPE > const &  elements,
SPECIFIC_TYPE *   
)
214 {
215 return elements._element.get_size();
216 }
TestRefManager< OBJECT > _element
Definition: ReferenceTypeListTest.cpp:155

References ContainerMapList< OBJECT >::_element.

Referenced by TypeRefContainer< OBJECT_TYPES >::count(), count(), and count_all().

+ Here is the caller graph for this function:

◆ count() [2/5]

template<class SPECIFIC_TYPE , class T >
size_t TypeListIterator::count ( ContainerMapList< T > const &  ,
SPECIFIC_TYPE *   
)
226 {
227 return 0;
228 }

◆ count() [3/5]

template<class SPECIFIC_TYPE , class H , class T >
size_t TypeListIterator::count ( ContainerMapList< TypeList< H, T > > const &  elements,
SPECIFIC_TYPE *  fake 
)
240 {
241 return count(elements._tail_elements, fake);
242 }
size_t count(ContainerMapList< TypeList< H, T > > const &elements, SPECIFIC_TYPE *fake)
Definition: ReferenceTypeListTest.cpp:239

References count().

+ Here is the call graph for this function:

◆ count() [4/5]

template<class SPECIFIC_TYPE , class T >
size_t TypeListIterator::count ( ContainerMapList< TypeList< SPECIFIC_TYPE, T > > const &  elements,
SPECIFIC_TYPE *  fake 
)
232 {
233 return count(elements._elements, fake);
234 }

References count().

+ Here is the call graph for this function:

◆ count() [5/5]

template<class SPECIFIC_TYPE >
size_t TypeListIterator::count ( ContainerMapList< TypeNull > const &  ,
SPECIFIC_TYPE *   
)
220 {
221 return 0;
222 }

◆ count_all() [1/2]

template<class H , class T >
size_t TypeListIterator::count_all ( ContainerMapList< TypeList< H, T > > const &  elements)
253 {
254 return count(elements._elements, (H *) nullptr) + count_all(elements._tail_elements);
255 }
size_t count_all(ContainerMapList< TypeList< H, T > > const &elements)
Definition: ReferenceTypeListTest.cpp:252

References count(), and count_all().

+ Here is the call graph for this function:

◆ count_all() [2/2]

template<class TypeNull >
size_t TypeListIterator::count_all ( ContainerMapList< TypeNull > const &  elements)
246 {
247 return 0;
248 }

Referenced by TypeRefContainer< OBJECT_TYPES >::count_all(), and count_all().

+ Here is the caller graph for this function:

◆ Insert() [1/4]

template<class SPECIFIC_TYPE >
SPECIFIC_TYPE * TypeListIterator::Insert ( ContainerMapList< SPECIFIC_TYPE > &  elements,
SPECIFIC_TYPE *  obj 
)
179 {
180 obj->add_reference(elements._element);
181 return obj;
182 }

References ContainerMapList< OBJECT >::_element.

Referenced by Insert(), and TypeRefContainer< OBJECT_TYPES >::insert().

+ Here is the caller graph for this function:

◆ Insert() [2/4]

template<class SPECIFIC_TYPE , class T >
SPECIFIC_TYPE * TypeListIterator::Insert ( ContainerMapList< T > &  ,
SPECIFIC_TYPE *   
)
193 {
194 return nullptr;
195 }

◆ Insert() [3/4]

template<class SPECIFIC_TYPE , class HEAD , class TAIL >
SPECIFIC_TYPE * TypeListIterator::Insert ( ContainerMapList< TypeList< HEAD, TAIL > > &  elements,
SPECIFIC_TYPE *  obj 
)
203 {
204 SPECIFIC_TYPE *t = Insert(elements._elements, obj);
205 return (t != nullptr ? t : Insert(elements._tail_elements, obj));
206 }
SPECIFIC_TYPE * Insert(ContainerMapList< TypeList< HEAD, TAIL > > &elements, SPECIFIC_TYPE *obj)
Definition: ReferenceTypeListTest.cpp:202
ContainerMapList< HEAD > _elements
Definition: ReferenceTypeListTest.cpp:166
ContainerMapList< TAIL > _tail_elements
Definition: ReferenceTypeListTest.cpp:167

References Insert().

+ Here is the call graph for this function:

◆ Insert() [4/4]

template<class SPECIFIC_TYPE >
SPECIFIC_TYPE * TypeListIterator::Insert ( ContainerMapList< TypeNull > &  ,
SPECIFIC_TYPE *   
)
186 {
187 return nullptr;
188 }