libosmscout 1.1.1
Loading...
Searching...
No Matches
osmscout::SpeedVariant Struct Reference

#include <libosmscout/include/osmscout/routing/RoutingProfile.h>

Collaboration diagram for osmscout::SpeedVariant:

Public Member Functions

const double & operator[] (Grade grade) const
double & operator[] (Grade grade)
void SetupValues ()
double Min () const
double Max () const

Static Public Member Functions

static SpeedVariant Fill (double speed)

Public Attributes

std::array< double, 5 > speed {NAN, NAN, NAN, NAN, NAN}
 speed for each grade, indexed by grade-1.

Detailed Description

Possible route speed variants by its grade.

Member Function Documentation

◆ Fill()

SpeedVariant osmscout::SpeedVariant::Fill ( double speed)
inlinestatic

◆ Max()

double osmscout::SpeedVariant::Max ( ) const
inline

◆ Min()

double osmscout::SpeedVariant::Min ( ) const
inline

◆ operator[]() [1/2]

double & osmscout::SpeedVariant::operator[] ( Grade grade)
inline

◆ operator[]() [2/2]

const double & osmscout::SpeedVariant::operator[] ( Grade grade) const
inline

◆ SetupValues()

void osmscout::SpeedVariant::SetupValues ( )
inline

Evaluate speed for all grades. When speed for grade is not defined, it copy speed from nearest "better".

Member Data Documentation

◆ speed

std::array<double,5> osmscout::SpeedVariant::speed {NAN, NAN, NAN, NAN, NAN}

speed for each grade, indexed by grade-1.


The documentation for this struct was generated from the following file: