Eclipse SUMO - Simulation of Urban MObility
MSPModel_NonInteracting Class Reference

The pedestrian following model. More...

#include <MSPModel_NonInteracting.h>

Inheritance diagram for MSPModel_NonInteracting:
[legend]
Collaboration diagram for MSPModel_NonInteracting:
[legend]

Data Structures

class  CState
 
class  MoveToNextEdge
 
class  PState
 implementation of callbacks to retrieve various state information from the model More...
 

Public Member Functions

MSTransportableStateAdapteradd (MSTransportable *transportable, MSStageMoving *stage, SUMOTime now)
 register the given transportable More...
 
virtual bool blockedAtDist (const MSLane *lane, double vehSide, double vehWidth, double oncomingGap, std::vector< const MSPerson * > *collectBlockers)
 whether a pedestrian is blocking the crossing of lane for the given vehicle bondaries More...
 
int getActiveNumber ()
 return the number of active objects More...
 
virtual bool hasPedestrians (const MSLane *lane)
 whether the given lane has pedestrians on it More...
 
MSTransportableStateAdapterloadState (MSTransportable *transportable, MSStageMoving *stage, std::istringstream &in)
 load the state of the given transportable More...
 
 MSPModel_NonInteracting (const OptionsCont &oc, MSNet *net)
 Constructor (it should not be necessary to construct more than one instance) More...
 
virtual PersonDist nextBlocking (const MSLane *lane, double minPos, double minRight, double maxLeft, double stopTime=0)
 returns the next pedestrian beyond minPos that is laterally between minRight and maxLeft or 0 More...
 
void registerArrived ()
 
void remove (MSTransportableStateAdapter *state)
 remove the specified person from the pedestrian simulation More...
 
bool usingInternalLanes ()
 whether movements on intersections are modelled More...
 
 ~MSPModel_NonInteracting ()
 

Static Public Member Functions

static int canTraverse (int dir, const ConstMSEdgeVector &route)
 

Static Public Attributes

static const int BACKWARD
 
static const int FORWARD
 
static const double SAFETY_GAP
 
static const double SIDEWALK_OFFSET
 the offset for computing person positions when walking on edges without a sidewalk More...
 
static const int UNDEFINED_DIRECTION
 

Private Attributes

MSNetmyNet
 the net to which to issue moveToNextEdge commands More...
 
int myNumActivePedestrians
 the total number of active pedestrians More...
 

Detailed Description

The pedestrian following model.

Definition at line 47 of file MSPModel_NonInteracting.h.

Constructor & Destructor Documentation

◆ MSPModel_NonInteracting()

MSPModel_NonInteracting::MSPModel_NonInteracting ( const OptionsCont oc,
MSNet net 
)

Constructor (it should not be necessary to construct more than one instance)

Definition at line 53 of file MSPModel_NonInteracting.cpp.

References myNet, and UNUSED_PARAMETER.

◆ ~MSPModel_NonInteracting()

MSPModel_NonInteracting::~MSPModel_NonInteracting ( )

Definition at line 61 of file MSPModel_NonInteracting.cpp.

Member Function Documentation

◆ add()

MSTransportableStateAdapter * MSPModel_NonInteracting::add ( MSTransportable transportable,
MSStageMoving stage,
SUMOTime  now 
)
virtual

◆ blockedAtDist()

virtual bool MSPModel::blockedAtDist ( const MSLane lane,
double  vehSide,
double  vehWidth,
double  oncomingGap,
std::vector< const MSPerson * > *  collectBlockers 
)
inlinevirtualinherited

whether a pedestrian is blocking the crossing of lane for the given vehicle bondaries

Parameters
[in]laneThe crossing to check
[in]vehSideThe offset to the vehicle side near the start of the crossing
[in]vehWidthThe width of the vehicle
[in]oncomingGapThe distance which the vehicle wants to keep from oncoming pedestrians
[in]collectBlockersThe list of persons blocking the crossing
Returns
Whether the vehicle must wait

Reimplemented in MSPModel_Striping.

Definition at line 78 of file MSPModel.h.

References UNUSED_PARAMETER.

Referenced by MSLink::getLeaderInfo().

Here is the caller graph for this function:

◆ canTraverse()

int MSPModel::canTraverse ( int  dir,
const ConstMSEdgeVector route 
)
staticinherited

Definition at line 52 of file MSPModel.cpp.

References MSPModel::BACKWARD, MSPModel::FORWARD, MSEdge::getFromJunction(), MSEdge::getToJunction(), and MSPModel::UNDEFINED_DIRECTION.

Referenced by MSPModel_Striping::PState::PState(), and MSPerson::MSPersonStage_Walking::walkDistance().

Here is the caller graph for this function:

◆ getActiveNumber()

int MSPModel_NonInteracting::getActiveNumber ( )
inlinevirtual

return the number of active objects

Implements MSPModel.

Definition at line 70 of file MSPModel_NonInteracting.h.

References myNumActivePedestrians.

◆ hasPedestrians()

virtual bool MSPModel::hasPedestrians ( const MSLane lane)
inlinevirtualinherited

whether the given lane has pedestrians on it

Reimplemented in MSPModel_Striping.

Definition at line 89 of file MSPModel.h.

References UNUSED_PARAMETER.

Referenced by MSLane::hasPedestrians().

Here is the caller graph for this function:

◆ loadState()

MSTransportableStateAdapter * MSPModel_NonInteracting::loadState ( MSTransportable transportable,
MSStageMoving stage,
std::istringstream &  in 
)
virtual

◆ nextBlocking()

virtual PersonDist MSPModel::nextBlocking ( const MSLane lane,
double  minPos,
double  minRight,
double  maxLeft,
double  stopTime = 0 
)
inlinevirtualinherited

returns the next pedestrian beyond minPos that is laterally between minRight and maxLeft or 0

Reimplemented in MSPModel_Striping.

Definition at line 95 of file MSPModel.h.

References UNUSED_PARAMETER.

Referenced by MSLane::nextBlocking().

Here is the caller graph for this function:

◆ registerArrived()

void MSPModel_NonInteracting::registerArrived ( )
inline

Definition at line 74 of file MSPModel_NonInteracting.h.

References myNumActivePedestrians.

Referenced by MSPModel_NonInteracting::MoveToNextEdge::~MoveToNextEdge().

Here is the caller graph for this function:

◆ remove()

void MSPModel_NonInteracting::remove ( MSTransportableStateAdapter state)
virtual

remove the specified person from the pedestrian simulation

Implements MSPModel.

Definition at line 86 of file MSPModel_NonInteracting.cpp.

References myNumActivePedestrians.

◆ usingInternalLanes()

bool MSPModel_NonInteracting::usingInternalLanes ( )
inlinevirtual

whether movements on intersections are modelled

Implements MSPModel.

Definition at line 65 of file MSPModel_NonInteracting.h.

Field Documentation

◆ BACKWARD

◆ FORWARD

◆ myNet

MSNet* MSPModel_NonInteracting::myNet
private

the net to which to issue moveToNextEdge commands

Definition at line 163 of file MSPModel_NonInteracting.h.

Referenced by add(), loadState(), and MSPModel_NonInteracting().

◆ myNumActivePedestrians

int MSPModel_NonInteracting::myNumActivePedestrians
private

the total number of active pedestrians

Definition at line 166 of file MSPModel_NonInteracting.h.

Referenced by add(), getActiveNumber(), loadState(), registerArrived(), and remove().

◆ SAFETY_GAP

◆ SIDEWALK_OFFSET

const double MSPModel::SIDEWALK_OFFSET
staticinherited

the offset for computing person positions when walking on edges without a sidewalk

Definition at line 113 of file MSPModel.h.

Referenced by MSPModel_NonInteracting::PState::getPosition(), GUINet::initGUIStructures(), and MSPModel_Striping::PState::moveToXY().

◆ UNDEFINED_DIRECTION


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