NIVissimExtendedEdgePoint Class Reference

#include <NIVissimExtendedEdgePoint.h>


Detailed Description

Definition at line 48 of file NIVissimExtendedEdgePoint.h.


Public Member Functions

int getEdgeID () const
Position2D getGeomPosition () const
const IntVectorgetLanes () const
SUMOReal getPosition () const
 NIVissimExtendedEdgePoint (int edgeid, const IntVector &lanes, SUMOReal position, const IntVector &assignedVehicles) throw ()
 Constructor.
void recheckLanes (const NBEdge *const edge) throw ()
 Resets lane numbers if all lanes shall be used.
 ~NIVissimExtendedEdgePoint ()

Private Attributes

IntVector myAssignedVehicles
int myEdgeID
IntVector myLanes
SUMOReal myPosition

Constructor & Destructor Documentation

NIVissimExtendedEdgePoint::NIVissimExtendedEdgePoint ( int  edgeid,
const IntVector lanes,
SUMOReal  position,
const IntVector assignedVehicles 
) throw ()

Constructor.

Parameters:
[in] edgeid The id of the Vissim-edge
[in] lanes Lanes on which this point lies
[in] position The position of this point at the edge
[in] assignedVehicles Vehicle (type) indices which should be regarded by this point

Definition at line 43 of file NIVissimExtendedEdgePoint.cpp.

00046         : myEdgeID(edgeid), myLanes(lanes), myPosition(position),
00047         myAssignedVehicles(assignedVehicles) {}

NIVissimExtendedEdgePoint::~NIVissimExtendedEdgePoint (  ) 

Definition at line 50 of file NIVissimExtendedEdgePoint.cpp.

00050 {}


Member Function Documentation

int NIVissimExtendedEdgePoint::getEdgeID (  )  const

Position2D NIVissimExtendedEdgePoint::getGeomPosition (  )  const

const IntVector & NIVissimExtendedEdgePoint::getLanes (  )  const

Definition at line 73 of file NIVissimExtendedEdgePoint.cpp.

References myLanes.

Referenced by NIVissimConnection::getFromLanes(), and NIVissimConnection::getToLanes().

00073                                           {
00074     return myLanes;
00075 }

SUMOReal NIVissimExtendedEdgePoint::getPosition (  )  const

void NIVissimExtendedEdgePoint::recheckLanes ( const NBEdge *const   edge  )  throw ()

Resets lane numbers if all lanes shall be used.

If myLanes contains a -1, the content of myLanes is replaced by indices of all lanes of the given edge.

Parameters:
[in] The built edge

Definition at line 79 of file NIVissimExtendedEdgePoint.cpp.

References myLanes.

Referenced by NIVissimConnection::recheckLanes().

00079                                                                          {
00080     // check whether an "all" indicator is there
00081     bool hadAll = false;
00082     for (IntVector::const_iterator i=myLanes.begin(); !hadAll&&i!=myLanes.end(); ++i) {
00083         if ((*i)==-1) {
00084             hadAll = true;
00085         }
00086     }
00087     // no -> return
00088     if (!hadAll) {
00089         return;
00090     }
00091     // patch lane indices
00092     myLanes.clear();
00093     for (int i=0; i<(int) edge->getNoLanes(); ++i) {
00094         myLanes.push_back(i);
00095     }
00096 }


Field Documentation

Definition at line 78 of file NIVissimExtendedEdgePoint.h.

Definition at line 75 of file NIVissimExtendedEdgePoint.h.

Referenced by getEdgeID(), and getGeomPosition().

Definition at line 76 of file NIVissimExtendedEdgePoint.h.

Referenced by getLanes(), and recheckLanes().

Definition at line 77 of file NIVissimExtendedEdgePoint.h.

Referenced by getGeomPosition(), and getPosition().


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

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