RODFEdgeBuilder Class Reference

#include <RODFEdgeBuilder.h>

Inheritance diagram for RODFEdgeBuilder:

ROAbstractEdgeBuilder

Detailed Description

Interface for building instances of dfrouter-edges.

This ROAbstractEdgeBuilder implementation builds edges for the duarouter (instances of RODFEdge).

See also:
RODFEdge

Definition at line 53 of file RODFEdgeBuilder.h.


Public Member Functions

 RODFEdgeBuilder () throw ()
 Constructor.
 ~RODFEdgeBuilder () throw ()
 Destructor.
Methods to be implemented, inherited from ROAbstractEdgeBuilder
ROEdgebuildEdge (const std::string &name, RONode *from, RONode *to) throw ()
 Builds an edge with the given name.

Protected Member Functions

unsigned int getNextIndex () throw ()
 Returns the index of the edge to built.

Constructor & Destructor Documentation

RODFEdgeBuilder::RODFEdgeBuilder (  )  throw ()

Constructor.

Definition at line 40 of file RODFEdgeBuilder.cpp.

00040 {}

RODFEdgeBuilder::~RODFEdgeBuilder (  )  throw ()

Destructor.

Definition at line 43 of file RODFEdgeBuilder.cpp.

00043 {}


Member Function Documentation

ROEdge * RODFEdgeBuilder::buildEdge ( const std::string &  name,
RONode from,
RONode to 
) throw () [virtual]

Builds an edge with the given name.

This implementation builds a RODFEdge.

Parameters:
[in] name The name of the edge
[in] from The node the edge begins at
[in] to The node the edge ends at
Returns:
A proper instance of the named edge
See also:
RODFEdge

Implements ROAbstractEdgeBuilder.

Definition at line 47 of file RODFEdgeBuilder.cpp.

References ROAbstractEdgeBuilder::getNextIndex().

00047                                                                                   {
00048     return new RODFEdge(name, from, to, getNextIndex());
00049 }

unsigned int ROAbstractEdgeBuilder::getNextIndex (  )  throw () [inline, protected, inherited]

Returns the index of the edge to built.

Returns:
Next valid edge index

Definition at line 87 of file ROAbstractEdgeBuilder.h.

References ROAbstractEdgeBuilder::myCurrentIndex.

Referenced by ROJTREdgeBuilder::buildEdge(), RODUAEdgeBuilder::buildEdge(), and buildEdge().

00087                                         {
00088         return myCurrentIndex++;
00089     }


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

Generated on Wed May 5 00:06:59 2010 for Sumo - Simulation of Urban MObility by  doxygen 1.5.6