CartoType C++ API 8.8-7-gb35e4dc71
for Windows, Linux, Qt and other platforms supporting C++ development
Public Member Functions | Public Attributes | List of all members
CartoTypeCore::Turn Class Reference

#include <cartotype_navigation.h>

Inheritance diagram for CartoTypeCore::Turn:
CartoTypeCore::NavigatorTurn

Public Member Functions

void Clear ()
 
void SetTurn (double aInDir, double aOutDir, int32_t aChoices, int32_t aLeftAlternatives, int32_t aRightAlternatives, bool aIsFork, bool aTurnOff)
 
void SetTurn (double aTurnAngle)
 
void WriteAsXml (OutputStream &aOutput) const
 

Public Attributes

CartoTypeCore::TurnType TurnType = CartoTypeCore::TurnType::None
 
bool IsContinue = true
 
CartoTypeCore::RoundaboutState RoundaboutState = CartoTypeCore::RoundaboutState::None
 
double TurnAngle = 0
 
double InDirection = 0
 
double OutDirection = 0
 
int32_t ExitNumber = 0
 
int32_t Choices = 0
 
int32_t LeftAlternatives = 0
 
int32_t RightAlternatives = 0
 
bool IsFork = false
 
bool IsTurnOff = false
 
String JunctionName
 
String JunctionRef
 

Detailed Description

A turn: a choice of route through a node.

Member Function Documentation

◆ Clear()

void CartoTypeCore::Turn::Clear ( )
inline

Sets the Turn object to its just-constructed state.

◆ SetTurn() [1/2]

void CartoTypeCore::Turn::SetTurn ( double  aInDir,
double  aOutDir,
int32_t  aChoices,
int32_t  aLeftAlternatives,
int32_t  aRightAlternatives,
bool  aIsFork,
bool  aTurnOff 
)
inline

Sets the Turn object using inward and outward direction in degrees (anticlockwise from map east), left and right alternative choices, and fork and turn-off flags.

◆ SetTurn() [2/2]

void CartoTypeCore::Turn::SetTurn ( double  aTurnAngle)
inline

Sets the Turn object's turn angle and turn type from an angle in degrees. Leaves other date members unchanged.

◆ WriteAsXml()

void CartoTypeCore::Turn::WriteAsXml ( OutputStream aOutput) const

Writes the Turn object in XML format as a turn element.

Member Data Documentation

◆ Choices

int32_t CartoTypeCore::Turn::Choices = 0

The number of choices at this turning if known; 0 if not known.

◆ ExitNumber

int32_t CartoTypeCore::Turn::ExitNumber = 0

The junction to take, counting the current junction as 0, if this junction is part of a roundabout.

◆ InDirection

double CartoTypeCore::Turn::InDirection = 0

The incoming direction in degrees relative to map east, going anticlockwise.

◆ IsContinue

bool CartoTypeCore::Turn::IsContinue = true

True if this turn is a continuation of the current road and no notification is needed.

◆ IsFork

bool CartoTypeCore::Turn::IsFork = false

True if this turn is a fork: that is, there is an alternative within 22.5 degrees of the turn actually taken.

◆ IsTurnOff

bool CartoTypeCore::Turn::IsTurnOff = false

True if this choice is a turn off, defined as a turn on to a lower-status road.

◆ JunctionName

String CartoTypeCore::Turn::JunctionName

The name of the junction.

◆ JunctionRef

String CartoTypeCore::Turn::JunctionRef

The reference code of the junction.

◆ LeftAlternatives

int32_t CartoTypeCore::Turn::LeftAlternatives = 0

The number of choices to the left of the turn actually taken; if iChoices is zero, this data is not known.

◆ OutDirection

double CartoTypeCore::Turn::OutDirection = 0

The outgoing direction in degrees relative to map east, going anticlockwise.

◆ RightAlternatives

int32_t CartoTypeCore::Turn::RightAlternatives = 0

The number of choices to the right of the turn actually taken; if iChoices is zero, this data is not known.

◆ RoundaboutState

The roundabout state.

◆ TurnAngle

double CartoTypeCore::Turn::TurnAngle = 0

The turn angle in degrees: 0 = straight ahead; negative = left, positive = right.

◆ TurnType

CartoTypeCore::TurnType CartoTypeCore::Turn::TurnType = CartoTypeCore::TurnType::None

The turn type: ahead, left, right, etc.


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