te::graph::AbstractIterator Class Referenceabstract

This class defines a commun interface to represents a graph iterator class. The main diferency to anothers iterators is the possibility to iterate over the edges or vertexs from a graph. More...

#include <AbstractIterator.h>

Inheritance diagram for te::graph::AbstractIterator:
te::graph::BoxIterator te::graph::MemoryIterator te::graph::QueryIterator te::graph::SequenceIterator

Public Member Functions

 AbstractIterator (te::graph::AbstractGraph *g)
 Default constructor. More...
 
virtual ~AbstractIterator ()
 Virtual destructor. More...
 
Vertex Iterator Methods

Method used to access vertex elements from a graph.

virtual te::graph::VertexgetFirstVertex ()=0
 It returns a pointer to the first vertex element of a graph. More...
 
virtual te::graph::VertexgetNextVertex ()
 It returns a pointer to the next vertex element of a graph. More...
 
virtual te::graph::VertexgetPreviousVertex ()
 It returns a pointer to the previous vertex element of a graph. More...
 
virtual bool isVertexIteratorAfterEnd ()
 Used to check the iterator position. More...
 
virtual size_t getVertexInteratorCount ()
 It returns the number of elements of this iterator. More...
 
void listIsolatedVertex (bool flag)
 Used to set that the isolated vertex must be listed. More...
 
virtual te::graph::EdgegetFirstEdge ()=0
 It returns a pointer to the first edge element of a graph. More...
 
virtual te::graph::EdgegetNextEdge ()
 It returns a pointer to the next edge element of a graph. More...
 
virtual te::graph::EdgegetPreviousEdge ()
 It returns a pointer to the previous edge element of a graph. More...
 
virtual bool isEdgeIteratorAfterEnd ()
 Used to check the iterator position. More...
 
virtual size_t getEdgeInteratorCount ()
 It returns the number of elements of this iterator. More...
 

Protected Attributes

std::auto_ptr< te::da::DataSetm_edgeQuery
 Attribute used to keep the edge iterator. More...
 
te::graph::AbstractGraphm_graph
 Pointer to a abstract graph used to access the elements. More...
 
bool m_listIsolatedVertex
 Flag used to indicated that the isolated vertex will be listed. More...
 
std::auto_ptr< te::da::DataSetm_vertexQuery
 Attribute used to keep the vertex iterator. More...
 

Detailed Description

This class defines a commun interface to represents a graph iterator class. The main diferency to anothers iterators is the possibility to iterate over the edges or vertexs from a graph.

See also

The sequency strategy is used to select a group of elements orderly.

See also
AbstractIterator

Definition at line 61 of file AbstractIterator.h.

Constructor & Destructor Documentation

te::graph::AbstractIterator::AbstractIterator ( te::graph::AbstractGraph g)

Default constructor.

virtual te::graph::AbstractIterator::~AbstractIterator ( )
virtual

Virtual destructor.

Member Function Documentation

virtual size_t te::graph::AbstractIterator::getEdgeInteratorCount ( )
virtual

It returns the number of elements of this iterator.

Returns
Size t value.

Reimplemented in te::graph::MemoryIterator.

virtual te::graph::Edge* te::graph::AbstractIterator::getFirstEdge ( )
pure virtual

It returns a pointer to the first edge element of a graph.

Returns
A valid edge point if the element was found and a null pointer in other case.

Implemented in te::graph::MemoryIterator, te::graph::BoxIterator, te::graph::QueryIterator, and te::graph::SequenceIterator.

virtual te::graph::Vertex* te::graph::AbstractIterator::getFirstVertex ( )
pure virtual

It returns a pointer to the first vertex element of a graph.

Returns
A valid vertex point if the element was found and a null pointer in other case.

Implemented in te::graph::BoxIterator, te::graph::QueryIterator, te::graph::SequenceIterator, and te::graph::MemoryIterator.

virtual te::graph::Edge* te::graph::AbstractIterator::getNextEdge ( )
virtual

It returns a pointer to the next edge element of a graph.

Returns
A valid edge point if the element was found and a null pointer in other case.

Reimplemented in te::graph::MemoryIterator.

virtual te::graph::Vertex* te::graph::AbstractIterator::getNextVertex ( )
virtual

It returns a pointer to the next vertex element of a graph.

Returns
A valid vertex point if the element was found and a null pointer in other case.

Reimplemented in te::graph::MemoryIterator.

virtual te::graph::Edge* te::graph::AbstractIterator::getPreviousEdge ( )
virtual

It returns a pointer to the previous edge element of a graph.

Returns
A valid edge point if the element was found and a null pointer in other case.

Reimplemented in te::graph::MemoryIterator.

virtual te::graph::Vertex* te::graph::AbstractIterator::getPreviousVertex ( )
virtual

It returns a pointer to the previous vertex element of a graph.

Returns
A valid vertex point if the element was found and a null pointer in other case.

Reimplemented in te::graph::MemoryIterator.

virtual size_t te::graph::AbstractIterator::getVertexInteratorCount ( )
virtual

It returns the number of elements of this iterator.

Returns
Size t value.

Reimplemented in te::graph::MemoryIterator.

virtual bool te::graph::AbstractIterator::isEdgeIteratorAfterEnd ( )
virtual

Used to check the iterator position.

Returns
True if the iterator is at after the end and false in other case

Reimplemented in te::graph::MemoryIterator.

virtual bool te::graph::AbstractIterator::isVertexIteratorAfterEnd ( )
virtual

Used to check the iterator position.

Returns
True if the iterator is at after the end and false in other case

Reimplemented in te::graph::MemoryIterator.

void te::graph::AbstractIterator::listIsolatedVertex ( bool  flag)

Used to set that the isolated vertex must be listed.

Parameters
flagFlag used to set.

Member Data Documentation

std::auto_ptr<te::da::DataSet> te::graph::AbstractIterator::m_edgeQuery
protected

Attribute used to keep the edge iterator.

Definition at line 168 of file AbstractIterator.h.

te::graph::AbstractGraph* te::graph::AbstractIterator::m_graph
protected

Pointer to a abstract graph used to access the elements.

Definition at line 165 of file AbstractIterator.h.

bool te::graph::AbstractIterator::m_listIsolatedVertex
protected

Flag used to indicated that the isolated vertex will be listed.

Definition at line 170 of file AbstractIterator.h.

std::auto_ptr<te::da::DataSet> te::graph::AbstractIterator::m_vertexQuery
protected

Attribute used to keep the vertex iterator.

Definition at line 167 of file AbstractIterator.h.


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