Cytopia  0.3
A city building simulation game
All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
ResourceManager::AgeIterator< Iterator > Struct Template Reference
+ Collaboration diagram for ResourceManager::AgeIterator< Iterator >:

Public Types

using value_type = decltype(ResourceItem< nullptr_t >().age)
 
using difference_type = size_t
 
using pointer = value_type *
 
using reference = const value_type &
 
using iterator_category = typename Iterator::iterator_category
 

Public Member Functions

 AgeIterator (Iterator it)
 
reference operator* () const
 
AgeIteratoroperator++ ()
 
bool operator!= (const AgeIterator &other) const
 
bool operator== (const AgeIterator &other) const
 

Private Attributes

Iterator it
 

Detailed Description

template<typename Iterator>
struct ResourceManager::AgeIterator< Iterator >

Definition at line 38 of file ResourceManager.hxx.

Member Typedef Documentation

◆ difference_type

template<typename Iterator >
using ResourceManager::AgeIterator< Iterator >::difference_type = size_t

Definition at line 41 of file ResourceManager.hxx.

◆ iterator_category

template<typename Iterator >
using ResourceManager::AgeIterator< Iterator >::iterator_category = typename Iterator::iterator_category

Definition at line 44 of file ResourceManager.hxx.

◆ pointer

template<typename Iterator >
using ResourceManager::AgeIterator< Iterator >::pointer = value_type *

Definition at line 42 of file ResourceManager.hxx.

◆ reference

template<typename Iterator >
using ResourceManager::AgeIterator< Iterator >::reference = const value_type &

Definition at line 43 of file ResourceManager.hxx.

◆ value_type

template<typename Iterator >
using ResourceManager::AgeIterator< Iterator >::value_type = decltype(ResourceItem<nullptr_t>().age)

Definition at line 40 of file ResourceManager.hxx.

Constructor & Destructor Documentation

◆ AgeIterator()

template<typename Iterator >
ResourceManager::AgeIterator< Iterator >::AgeIterator ( Iterator  it)
inline

Definition at line 45 of file ResourceManager.hxx.

45 : it(it) {}

Member Function Documentation

◆ operator!=()

template<typename Iterator >
bool ResourceManager::AgeIterator< Iterator >::operator!= ( const AgeIterator< Iterator > &  other) const
inline

Definition at line 52 of file ResourceManager.hxx.

52 { return other.it != it; }

◆ operator*()

template<typename Iterator >
reference ResourceManager::AgeIterator< Iterator >::operator* ( ) const
inline

Definition at line 46 of file ResourceManager.hxx.

46 { return (it->second).age; }

◆ operator++()

template<typename Iterator >
AgeIterator& ResourceManager::AgeIterator< Iterator >::operator++ ( )
inline

Definition at line 47 of file ResourceManager.hxx.

48  {
49  ++it;
50  return *this;
51  }

◆ operator==()

template<typename Iterator >
bool ResourceManager::AgeIterator< Iterator >::operator== ( const AgeIterator< Iterator > &  other) const
inline

Definition at line 53 of file ResourceManager.hxx.

53 { return other.it == it; }

Member Data Documentation

◆ it

template<typename Iterator >
Iterator ResourceManager::AgeIterator< Iterator >::it
private

Definition at line 56 of file ResourceManager.hxx.


The documentation for this struct was generated from the following file:
ResourceManager::AgeIterator::it
Iterator it
Definition: ResourceManager.hxx:56