DiaDes  0.1
DIAgnosis of Discrete-Event System
Public Types | Public Member Functions | Static Public Member Functions | Public Attributes | List of all members
Diades::Graph::GraphIterator< Any > Struct Template Reference

#include <GraphInt.hh>

Public Types

typedef Diades::Utils::Exception< GraphIteratorException
 
typedef GraphIterator< Any > self
 
typedef ptrdiff_t difference_type
 
typedef std::forward_iterator_tag iterator_category
 
typedef Any value_type
 
typedef Any * pointer
 
typedef Any & reference
 
typedef vector< value_type >::size_type SizeType
 

Public Member Functions

 GraphIterator ()
 
 GraphIterator (vector< value_type > *pVect, SizeType index)
 
reference operator* () const
 
pointer operator-> () const
 
selfoperator++ ()
 
self operator++ (int)
 
bool operator== (const self &it) const
 
bool operator!= (const self &it) const
 

Static Public Member Functions

static string typeName ()
 

Public Attributes

vector< value_type > * _pVect
 
SizeType _index
 

Detailed Description

template<typename Any>
struct Diades::Graph::GraphIterator< Any >

Define an iterator on the Graph (template for NodeIterator and EdgeIterator

Definition at line 24 of file GraphInt.hh.

Member Typedef Documentation

◆ difference_type

template<typename Any>
typedef ptrdiff_t Diades::Graph::GraphIterator< Any >::difference_type

Definition at line 34 of file GraphInt.hh.

◆ Exception

Definition at line 29 of file GraphInt.hh.

◆ iterator_category

template<typename Any>
typedef std::forward_iterator_tag Diades::Graph::GraphIterator< Any >::iterator_category

Definition at line 35 of file GraphInt.hh.

◆ pointer

template<typename Any>
typedef Any* Diades::Graph::GraphIterator< Any >::pointer

Definition at line 37 of file GraphInt.hh.

◆ reference

template<typename Any>
typedef Any& Diades::Graph::GraphIterator< Any >::reference

Definition at line 38 of file GraphInt.hh.

◆ self

template<typename Any>
typedef GraphIterator<Any> Diades::Graph::GraphIterator< Any >::self

Definition at line 33 of file GraphInt.hh.

◆ SizeType

template<typename Any>
typedef vector<value_type>::size_type Diades::Graph::GraphIterator< Any >::SizeType

Definition at line 40 of file GraphInt.hh.

◆ value_type

template<typename Any>
typedef Any Diades::Graph::GraphIterator< Any >::value_type

Definition at line 36 of file GraphInt.hh.

Constructor & Destructor Documentation

◆ GraphIterator() [1/2]

template<typename Any>
Diades::Graph::GraphIterator< Any >::GraphIterator ( )
inline

Default constructor

Definition at line 48 of file GraphInt.hh.

◆ GraphIterator() [2/2]

template<typename Any>
Diades::Graph::GraphIterator< Any >::GraphIterator ( vector< value_type > *  pVect,
SizeType  index 
)
inlineexplicit

Constructor

Parameters
pVectpointer on a vector
indexindex in that vector

Definition at line 56 of file GraphInt.hh.

Member Function Documentation

◆ operator!=()

template<typename Any>
bool Diades::Graph::GraphIterator< Any >::operator!= ( const self it) const
inline
Parameters
itan iterator
Returns
true if both iterators are not equal

Definition at line 130 of file GraphInt.hh.

◆ operator*()

template<typename Any>
reference Diades::Graph::GraphIterator< Any >::operator* ( ) const
inline
Returns
a reference on the object the iterator refers to

Definition at line 72 of file GraphInt.hh.

◆ operator++() [1/2]

template<typename Any>
self& Diades::Graph::GraphIterator< Any >::operator++ ( )
inline

Increment the iterator

Returns
the next position

Definition at line 90 of file GraphInt.hh.

Referenced by Diades::Graph::GraphIterator< Edge >::GraphIterator().

◆ operator++() [2/2]

template<typename Any>
self Diades::Graph::GraphIterator< Any >::operator++ ( int  )
inline

Increment the iterator

Returns
the previous position

Definition at line 105 of file GraphInt.hh.

◆ operator->()

template<typename Any>
pointer Diades::Graph::GraphIterator< Any >::operator-> ( ) const
inline
Returns
a pointer on the object the iterator refers to

Definition at line 81 of file GraphInt.hh.

◆ operator==()

template<typename Any>
bool Diades::Graph::GraphIterator< Any >::operator== ( const self it) const
inline
Parameters
itan iterator
Returns
true if both iterators are equal

Definition at line 121 of file GraphInt.hh.

◆ typeName()

template<typename Any>
static string Diades::Graph::GraphIterator< Any >::typeName ( )
inlinestatic

Definition at line 26 of file GraphInt.hh.

Member Data Documentation

◆ _index

template<typename Any>
SizeType Diades::Graph::GraphIterator< Any >::_index

◆ _pVect

template<typename Any>
vector<value_type>* Diades::Graph::GraphIterator< Any >::_pVect

Definition at line 42 of file GraphInt.hh.


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