SUMO - Simulation of Urban MObility
NBPTStop Class Reference

The representation of a single pt stop. More...

#include <NBPTStop.h>

Collaboration diagram for NBPTStop:
Collaboration graph

Public Member Functions

void addAccess (std::string laneID, double offset, double length)
 
void addLine (const std::string &line)
 register line that services this stop (for displaying) More...
 
void addPlatformCand (NBPTPlatform platform)
 
void clearAccess ()
 remove all access definitions More...
 
void computExtent (double center, double d)
 
bool findLaneAndComputeBusStopExtend (NBEdgeCont &ec)
 
NBPTStopgetBidiStop () const
 
const std::string getEdgeId () const
 
std::string getID () const
 
bool getIsMultipleStopPositions () const
 
double getLength () const
 
const std::map< std::string, std::string > & getMyAdditionalEdgeCandidates () const
 
const std::string getName () const
 
const std::string getOrigEdgeId () const
 
SVCPermissions getPermissions () const
 
const std::vector< NBPTPlatform > & getPlatformCands ()
 
const PositiongetPosition () const
 
 NBPTStop (std::string ptStopId, Position position, std::string edgeId, std::string origEdgeId, double length, std::string name, SVCPermissions svcPermissions)
 Constructor. More...
 
void registerAdditionalEdge (std::string wayId, std::string edgeId)
 
void reshiftPosition (const double offsetX, const double offsetY)
 
void setBidiStop (NBPTStop *bidiStop)
 
bool setEdgeId (std::string edgeId, NBEdgeCont &ec)
 
void setIsMultipleStopPositions (bool multipleStopPositions)
 
void setMyOrigEdgeId (const std::string &myOrigEdgeId)
 
void setMyPTStopId (std::string id)
 
void setMyPTStopLength (double myPTStopLength)
 
void write (OutputDevice &device)
 

Private Member Functions

NBPTStopoperator= (const NBPTStop &)
 Invalidated assignment operator. More...
 

Private Attributes

std::vector< std::tuple< std::string, double, double > > myAccesses
 laneId, lanePos, accessLength More...
 
std::map< std::string, std::string > myAdditionalEdgeCandidates
 
NBPTStopmyBidiStop
 
std::string myEdgeId
 
double myEndPos
 
bool myIsMultipleStopPositions
 
std::string myLaneId
 
std::vector< std::string > myLines
 list of public transport lines (for displaying) More...
 
const std::string myName
 
std::string myOrigEdgeId
 
const SVCPermissions myPermissions
 
std::vector< NBPTPlatformmyPlatformCands
 
Position myPosition
 
std::string myPTStopId
 
double myPTStopLength
 
double myStartPos
 

Detailed Description

The representation of a single pt stop.

Definition at line 45 of file NBPTStop.h.

Constructor & Destructor Documentation

◆ NBPTStop()

NBPTStop::NBPTStop ( std::string  ptStopId,
Position  position,
std::string  edgeId,
std::string  origEdgeId,
double  length,
std::string  name,
SVCPermissions  svcPermissions 
)

Constructor.

Parameters
[in]idThe id of the pt stop
[in]positionThe position of the pt stop
[in]edgeIdThe edge id of the pt stop
[in]lengthThe length of the pt stop

Definition at line 34 of file NBPTStop.cpp.

Member Function Documentation

◆ addAccess()

void NBPTStop::addAccess ( std::string  laneID,
double  offset,
double  length 
)

Definition at line 232 of file NBPTStop.cpp.

References SUMOXMLDefinitions::getEdgeIDFromLane(), and myAccesses.

Referenced by NIXMLPTHandler::addAccess().

◆ addLine()

void NBPTStop::addLine ( const std::string &  line)

register line that services this stop (for displaying)

Definition at line 84 of file NBPTStop.cpp.

References StringUtils::escapeXML(), and myLines.

◆ addPlatformCand()

void NBPTStop::addPlatformCand ( NBPTPlatform  platform)

Definition at line 137 of file NBPTStop.cpp.

References myPlatformCands.

Referenced by NIImporter_OpenStreetMap::RelationHandler::myEndElement().

◆ clearAccess()

void NBPTStop::clearAccess ( )

remove all access definitions

Definition at line 227 of file NBPTStop.cpp.

References myAccesses.

◆ computExtent()

void NBPTStop::computExtent ( double  center,
double  d 
)

Definition at line 77 of file NBPTStop.cpp.

References MAX2(), MIN2(), myEndPos, myPTStopLength, and myStartPos.

Referenced by findLaneAndComputeBusStopExtend().

◆ findLaneAndComputeBusStopExtend()

◆ getBidiStop()

NBPTStop* NBPTStop::getBidiStop ( ) const
inline

Definition at line 88 of file NBPTStop.h.

References myBidiStop.

Referenced by NBPTLineCont::fixBidiStops().

◆ getEdgeId()

◆ getID()

std::string NBPTStop::getID ( ) const

◆ getIsMultipleStopPositions()

bool NBPTStop::getIsMultipleStopPositions ( ) const

Definition at line 149 of file NBPTStop.cpp.

References myIsMultipleStopPositions.

Referenced by NBPTStopCont::localizePTStops().

◆ getLength()

double NBPTStop::getLength ( ) const

Definition at line 161 of file NBPTStop.cpp.

References myPTStopLength.

Referenced by NBPTStopCont::generateBidiStops(), and NBPTStopCont::getReverseStop().

◆ getMyAdditionalEdgeCandidates()

const std::map< std::string, std::string > & NBPTStop::getMyAdditionalEdgeCandidates ( ) const

Definition at line 180 of file NBPTStop.cpp.

References myAdditionalEdgeCandidates.

◆ getName()

const std::string NBPTStop::getName ( ) const

Definition at line 65 of file NBPTStop.cpp.

References myName.

Referenced by NBPTStopCont::generateBidiStops(), and NBPTStopCont::getReverseStop().

◆ getOrigEdgeId()

const std::string NBPTStop::getOrigEdgeId ( ) const

Definition at line 53 of file NBPTStop.cpp.

References myOrigEdgeId.

Referenced by NBPTStopCont::generateBidiStops().

◆ getPermissions()

SVCPermissions NBPTStop::getPermissions ( ) const

◆ getPlatformCands()

const std::vector< NBPTPlatform > & NBPTStop::getPlatformCands ( )

◆ getPosition()

◆ operator=()

NBPTStop& NBPTStop::operator= ( const NBPTStop )
private

Invalidated assignment operator.

◆ registerAdditionalEdge()

void NBPTStop::registerAdditionalEdge ( std::string  wayId,
std::string  edgeId 
)

Definition at line 174 of file NBPTStop.cpp.

References myAdditionalEdgeCandidates.

Referenced by NIImporter_OpenStreetMap::insertEdge().

◆ reshiftPosition()

void NBPTStop::reshiftPosition ( const double  offsetX,
const double  offsetY 
)

Definition at line 122 of file NBPTStop.cpp.

References Position::add(), myPlatformCands, and myPosition.

◆ setBidiStop()

void NBPTStop::setBidiStop ( NBPTStop bidiStop)
inline

Definition at line 84 of file NBPTStop.h.

References myBidiStop.

Referenced by NBPTStopCont::generateBidiStops().

◆ setEdgeId()

bool NBPTStop::setEdgeId ( std::string  edgeId,
NBEdgeCont ec 
)

◆ setIsMultipleStopPositions()

void NBPTStop::setIsMultipleStopPositions ( bool  multipleStopPositions)

◆ setMyOrigEdgeId()

void NBPTStop::setMyOrigEdgeId ( const std::string &  myOrigEdgeId)

Definition at line 186 of file NBPTStop.cpp.

References myOrigEdgeId.

◆ setMyPTStopId()

void NBPTStop::setMyPTStopId ( std::string  id)

Definition at line 222 of file NBPTStop.cpp.

References myPTStopId.

◆ setMyPTStopLength()

void NBPTStop::setMyPTStopLength ( double  myPTStopLength)

◆ write()

Field Documentation

◆ myAccesses

std::vector<std::tuple<std::string, double, double> > NBPTStop::myAccesses
private

laneId, lanePos, accessLength

Definition at line 116 of file NBPTStop.h.

Referenced by addAccess(), clearAccess(), and write().

◆ myAdditionalEdgeCandidates

std::map<std::string, std::string> NBPTStop::myAdditionalEdgeCandidates
private

Definition at line 96 of file NBPTStop.h.

Referenced by getMyAdditionalEdgeCandidates(), and registerAdditionalEdge().

◆ myBidiStop

NBPTStop* NBPTStop::myBidiStop
private

Definition at line 121 of file NBPTStop.h.

Referenced by getBidiStop(), and setBidiStop().

◆ myEdgeId

std::string NBPTStop::myEdgeId
private

Definition at line 95 of file NBPTStop.h.

Referenced by findLaneAndComputeBusStopExtend(), getEdgeId(), and setEdgeId().

◆ myEndPos

double NBPTStop::myEndPos
private

Definition at line 113 of file NBPTStop.h.

Referenced by computExtent(), and write().

◆ myIsMultipleStopPositions

bool NBPTStop::myIsMultipleStopPositions
private

Definition at line 130 of file NBPTStop.h.

Referenced by getIsMultipleStopPositions(), and setIsMultipleStopPositions().

◆ myLaneId

std::string NBPTStop::myLaneId
private

Definition at line 109 of file NBPTStop.h.

Referenced by findLaneAndComputeBusStopExtend(), and write().

◆ myLines

std::vector<std::string> NBPTStop::myLines
private

list of public transport lines (for displaying)

Definition at line 119 of file NBPTStop.h.

Referenced by addLine(), and write().

◆ myName

const std::string NBPTStop::myName
private

Definition at line 108 of file NBPTStop.h.

Referenced by getName(), and write().

◆ myOrigEdgeId

std::string NBPTStop::myOrigEdgeId
private

Definition at line 100 of file NBPTStop.h.

Referenced by getOrigEdgeId(), and setMyOrigEdgeId().

◆ myPermissions

const SVCPermissions NBPTStop::myPermissions
private

Definition at line 110 of file NBPTStop.h.

Referenced by getPermissions().

◆ myPlatformCands

std::vector<NBPTPlatform> NBPTStop::myPlatformCands
private

Definition at line 129 of file NBPTStop.h.

Referenced by addPlatformCand(), getPlatformCands(), and reshiftPosition().

◆ myPosition

Position NBPTStop::myPosition
private

Definition at line 94 of file NBPTStop.h.

Referenced by getPosition(), and reshiftPosition().

◆ myPTStopId

std::string NBPTStop::myPTStopId
private

Definition at line 93 of file NBPTStop.h.

Referenced by getID(), setMyPTStopId(), and write().

◆ myPTStopLength

double NBPTStop::myPTStopLength
private

Definition at line 104 of file NBPTStop.h.

Referenced by computExtent(), getLength(), and setMyPTStopLength().

◆ myStartPos

double NBPTStop::myStartPos
private

Definition at line 112 of file NBPTStop.h.

Referenced by computExtent(), and write().


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