WSF
XWsfRoadTraffic::WeightedRouteSegment Class Reference

#include <XWsfRoadTraffic.hpp>

Collaboration diagram for XWsfRoadTraffic::WeightedRouteSegment:

Public Member Functions

 WeightedRouteSegment ()=default
 WeightedRouteSegment (WsfRoute *aRoutePtr, const WsfWaypoint &aNode1, const WsfWaypoint &aNode2)
bool operator== (double aWeight) const
 Equal if the provided weight is enclosed by this segment's boundary weights.
bool operator< (const WeightedRouteSegment &aSegment) const

Public Attributes

WsfRoutemRoutePtr = nullptr
WsfWaypoint mNode1
WsfWaypoint mNode2
double mNode1Weight = 0.0
double mNode2Weight = 0.0
double mSegmentWeight = 0.0
double mCumulativeWeight = 0.0

Detailed Description

WeightedRouteSegment represents the concept of a weighted edge in a graph. It includes the two endpoints and their respective weights as well as the edge's weight. The NetworkInput class includes a list of WeightedRouteSegments that define the network graph.

Constructor & Destructor Documentation

◆ WeightedRouteSegment() [1/2]

XWsfRoadTraffic::WeightedRouteSegment::WeightedRouteSegment ( )
default

Referenced by operator<().

◆ WeightedRouteSegment() [2/2]

XWsfRoadTraffic::WeightedRouteSegment::WeightedRouteSegment ( WsfRoute * aRoutePtr,
const WsfWaypoint & aNode1,
const WsfWaypoint & aNode2 )
inline

References mNode1, mNode2, and mRoutePtr.

Member Function Documentation

◆ operator<()

bool XWsfRoadTraffic::WeightedRouteSegment::operator< ( const WeightedRouteSegment & aSegment) const
inline

◆ operator==()

bool XWsfRoadTraffic::WeightedRouteSegment::operator== ( double aWeight) const
inline

Equal if the provided weight is enclosed by this segment's boundary weights.

References mCumulativeWeight, and mSegmentWeight.

Member Data Documentation

◆ mCumulativeWeight

double XWsfRoadTraffic::WeightedRouteSegment::mCumulativeWeight = 0.0

Referenced by operator==().

◆ mNode1

WsfWaypoint XWsfRoadTraffic::WeightedRouteSegment::mNode1

Referenced by WeightedRouteSegment().

◆ mNode1Weight

double XWsfRoadTraffic::WeightedRouteSegment::mNode1Weight = 0.0

◆ mNode2

WsfWaypoint XWsfRoadTraffic::WeightedRouteSegment::mNode2

Referenced by WeightedRouteSegment().

◆ mNode2Weight

double XWsfRoadTraffic::WeightedRouteSegment::mNode2Weight = 0.0

◆ mRoutePtr

WsfRoute* XWsfRoadTraffic::WeightedRouteSegment::mRoutePtr = nullptr

Referenced by WeightedRouteSegment().

◆ mSegmentWeight

double XWsfRoadTraffic::WeightedRouteSegment::mSegmentWeight = 0.0

Referenced by operator<(), and operator==().


The documentation for this class was generated from the following file:
Copyrights Multiple, All Rights Reserved